CN106330134B - A kind of crystal-oscillator circuit and its tuning methods - Google Patents

A kind of crystal-oscillator circuit and its tuning methods Download PDF

Info

Publication number
CN106330134B
CN106330134B CN201510369109.7A CN201510369109A CN106330134B CN 106330134 B CN106330134 B CN 106330134B CN 201510369109 A CN201510369109 A CN 201510369109A CN 106330134 B CN106330134 B CN 106330134B
Authority
CN
China
Prior art keywords
control word
temperature
crystal
frequency
oscillator circuit
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
CN201510369109.7A
Other languages
Chinese (zh)
Other versions
CN106330134A (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.)
Shenzhen ZTE Microelectronics Technology Co Ltd
Original Assignee
Shenzhen ZTE Microelectronics Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen ZTE Microelectronics Technology Co Ltd filed Critical Shenzhen ZTE Microelectronics Technology Co Ltd
Priority to CN201510369109.7A priority Critical patent/CN106330134B/en
Priority to PCT/CN2016/074685 priority patent/WO2017000571A1/en
Publication of CN106330134A publication Critical patent/CN106330134A/en
Application granted granted Critical
Publication of CN106330134B publication Critical patent/CN106330134B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03JTUNING RESONANT CIRCUITS; SELECTING RESONANT CIRCUITS
    • H03J7/00Automatic frequency control; Automatic scanning over a band of frequencies
    • H03J7/02Automatic frequency control
    • H03J7/04Automatic frequency control where the frequency control is accomplished by varying the electrical characteristics of a non-mechanically adjustable element or where the nature of the frequency controlling element is not significant

Landscapes

  • Oscillators With Electromechanical Resonators (AREA)

Abstract

The invention discloses a kind of tuning methods of crystal-oscillator circuit, which comprises obtains the first control word according to current digital voltage signal and temperature compensation table;The second control word is obtained according to current automatic frequency control (AFC) control word and nonlinear compensation table;Capacitor array is adjusted according to first control word and the second control word, to realize the frequency for tuning the crystal-oscillator circuit.The invention also discloses a kind of crystal-oscillator circuits.

Description

Crystal oscillator circuit and tuning method thereof
Technical Field
The invention relates to the technical field of crystal oscillators, in particular to a crystal oscillator circuit and a tuning method thereof.
Background
Digital Compensated Crystal Oscillator (DCXO) circuits are widely used in modern wireless communication chip systems, and generally consist of: the oscillator amplifier provides negative resistance required by oscillation, ensures an amplitude detection and control circuit of oscillation starting, and has a design that a temperature compensation circuit is added to correct the drift of oscillation frequency caused by temperature change.
Most methods for realizing circuit tuning of the crystal oscillator in the prior art are large and complex in circuit, low in frequency accuracy and high in realization cost; therefore, it is desirable to provide a crystal oscillator circuit and a tuning method thereof, which can improve the frequency accuracy of the crystal oscillator circuit, and have high reliability and low cost.
Disclosure of Invention
In view of this, embodiments of the present invention are expected to provide a crystal oscillator circuit and a tuning method thereof, which can improve the frequency accuracy of the crystal oscillator circuit, enhance the user experience, and have high reliability and low cost.
In order to achieve the above purpose, the technical solution of the embodiment of the present invention is realized as follows:
the embodiment of the invention provides a tuning method of a crystal oscillator circuit, which comprises the following steps:
acquiring a first control word according to the current digital voltage signal and a temperature compensation table;
acquiring a second Control word according to a current Automatic Frequency Control (AFC) Control word and a nonlinear compensation table;
and adjusting the capacitor array according to the first control word and the second control word to realize the tuning of the frequency of the crystal oscillator circuit.
In the above scheme, the current digital voltage signal is obtained by converting an input analog voltage signal and is related to temperature.
In the foregoing solution, before the obtaining the first control word according to the current digital voltage signal and the temperature compensation table, the method further includes:
and determining the temperature coefficient of the crystal, and acquiring a temperature compensation table corresponding to the crystal according to the determined temperature coefficient.
In the foregoing solution, the obtaining the first control word according to the current digital voltage signal and the temperature compensation table includes:
determining a corresponding temperature value according to the current digital voltage signal, acquiring a first compensation capacitor corresponding to the temperature value in a temperature compensation table in a lookup table mode according to the temperature value, and generating a first control word according to the first compensation capacitor.
In the foregoing solution, the obtaining a second control word according to a current AFC control word and a non-linear compensation table includes:
and acquiring a second compensation capacitor corresponding to the AFC control word in a nonlinear compensation table in a lookup table mode according to the current AFC control word, and generating a second control word according to the second compensation capacitor.
In the foregoing solution, the adjusting the capacitor array according to the first control word and the second control word to tune the frequency of the crystal oscillator circuit includes:
and adding the first control word and the second control word to obtain a third control word, and adjusting the size of the capacitor array according to the third control word to realize the tuning of the frequency of the crystal oscillator circuit.
An embodiment of the present invention further provides a crystal oscillator circuit, where the crystal oscillator circuit includes: the temperature compensation circuit, the nonlinear compensation circuit and the tuning circuit; wherein,
the temperature compensation circuit is used for acquiring a first control word according to the current digital voltage signal and the temperature compensation table;
the nonlinear compensation circuit is used for acquiring a second control word according to the current AFC control word and the nonlinear compensation table;
and the tuning circuit is used for adjusting the capacitor array according to the first control word and the second control word so as to tune the frequency of the crystal oscillator circuit.
In the above scheme, the current digital voltage signal is obtained by converting an input analog voltage signal and is related to temperature;
correspondingly, the crystal oscillator circuit further comprises an analog-to-digital converter for converting the input analog voltage signal into a corresponding digital voltage signal.
In the above scheme, the crystal oscillator circuit further includes a processor configured to determine a temperature coefficient of the crystal, and obtain a temperature compensation table corresponding to the crystal according to the determined temperature coefficient.
In the above scheme, the temperature compensation circuit is specifically configured to determine a corresponding temperature value according to a current digital voltage signal, obtain a first compensation capacitor corresponding to the temperature value in a temperature compensation table by using a lookup table according to the temperature value, and generate a first control word according to the first compensation capacitor.
In the foregoing solution, the nonlinear compensation circuit is specifically configured to obtain a second compensation capacitor corresponding to an AFC control word in a nonlinear compensation table by using a lookup table according to the current AFC control word, and generate a second control word according to the second compensation capacitor.
In the foregoing scheme, the tuning circuit is specifically configured to add the first control word and the second control word to obtain a third control word, and adjust the size of the capacitor array according to the third control word, so as to tune the frequency of the crystal oscillator circuit.
According to the crystal oscillator circuit and the tuning method thereof provided by the embodiment of the invention, a first control word is obtained according to a current digital voltage signal and a temperature compensation table; acquiring a second control word according to the current AFC control word and the nonlinear compensation table; and adjusting the capacitor array according to the first control word and the second control word to realize the tuning of the frequency of the crystal oscillator circuit. Therefore, the tuning of the crystal oscillator circuit is realized according to the current digital voltage signal and the control word generated by the current AFC control word, the frequency accuracy and the temperature characteristic of the crystal oscillator circuit can be improved, the user experience is enhanced, and the crystal oscillator circuit is high in reliability and low in cost.
Drawings
FIG. 1 is a flow chart of a tuning method of a crystal oscillator circuit according to an embodiment of the invention;
FIG. 2 is a flow chart illustrating a tuning method of a two-crystal oscillator circuit according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a circuit structure of a crystal oscillator according to an embodiment of the present invention.
Detailed Description
In the embodiment of the invention, a first control word is obtained according to a current digital voltage signal and a temperature compensation table; acquiring a second control word according to the current AFC control word and the nonlinear compensation table; and adjusting the capacitor array according to the first control word and the second control word to realize the tuning of the frequency of the crystal oscillator circuit.
Example one
Fig. 1 is a schematic flow chart illustrating a tuning method of a crystal oscillator circuit according to an embodiment of the present invention, and as shown in fig. 1, the tuning method of the crystal oscillator circuit according to the embodiment of the present invention includes:
step 101: acquiring a first control word according to the current digital voltage signal and a temperature compensation table;
this step can be implemented by a temperature compensation circuit in the crystal oscillator circuit;
the method specifically comprises the following steps: determining a corresponding temperature value according to a current digital voltage signal, acquiring a first compensation capacitor corresponding to the temperature value in a temperature compensation table in a lookup table mode according to the temperature value, and generating a first control word according to the first compensation capacitor; the first control word is used for representing the size of a compensation capacitor required by the corresponding current digital voltage signal; the first compensation capacitor corresponding to the temperature value is the minimum unit capacitor number corresponding to the temperature value, namely the first compensation capacitor is represented by the minimum unit capacitor number.
Here, the current digital voltage signal is obtained by converting an analog voltage signal input by the temperature sensing circuit through an analog-to-digital converter and inputting the analog voltage signal to the temperature compensation circuit; the analog voltage signal is generated by the temperature sensing circuit and changes along with the temperature change, namely the analog voltage signal is related to the temperature, namely the digital voltage signal is related to the temperature, and the specific relation is determined according to the currently adopted temperature sensor, for example, when the current temperature sensor is realized by adopting a thermistor, the digital voltage signal is approximately in a linear relation with the temperature;
determining the corresponding temperature value according to the current digital voltage signal includes: and determining a corresponding temperature value according to the current digital voltage signal and the corresponding relation between the digital voltage signal and the temperature value.
Further, before the obtaining the first control word according to the current digital voltage signal and the temperature compensation table, the method further includes:
determining the temperature coefficient of the crystal, and acquiring a temperature compensation table corresponding to the crystal according to the determined temperature coefficient; the operation can be completed in an automatic test before the terminal containing the crystal oscillator circuit leaves a factory, particularly in a frequency coarse adjustment process of the automatic test;
wherein the temperature coefficient of the crystal comprises: first temperature coefficient a1A second temperature coefficient a2And a third temperature coefficient a3
The frequency-temperature characteristic of the crystal can be expressed as: Δ fc(T)=a3(T-T0)3+a2(T-T0)2+a1(T-T0);
Wherein, T0Is the inflection temperature of the crystal, about 25 °; the crystal may be AT cut;
Δfc(T) represents the amount of change in frequency at a temperature T.
Further, the determining the temperature coefficient of the crystal comprises:
obtaining the frequency difference delta f (T) when the crystal temperature is T1 and T33)-f(T1) Obtaining the temperature coefficient of the crystal according to the corresponding relation between the frequency difference delta f and the temperature coefficient; wherein, (T2-Delta T)<T1<T2,T2<T3<(T2+ΔT),T1About 25 ° for the inflection temperature of the crystal; the corresponding relation between the frequency difference deltaf and the temperature coefficient can be obtained by looking up a table.
In a crystal oscillator circuit, the input resistance of an amplifier needs to be matched with the series resonance impedance of a crystal, but the input impedance of the amplifier is usually high, so that the impedance of the amplifier and the impedance of the crystal may be mismatched during series resonance0The frequency response is worse than the series resonance, so a capacitor is usually connected in parallel across the crystal to lower C0The effect on the parallel resonant frequency; in parallel connection with a capacitor CLThe resonant frequency of the circuit can then be expressed as:
wherein, CSIs the dynamic capacitance of the crystal; l isSA dynamic inductance that is a crystal; c0Is a static capacitance; from series resonance frequency
Parallel resonant frequencyIt is possible to obtain,
according to the above formula, the load capacitance C can be adjustedLTo realize the change of the oscillation frequency of the crystal oscillator, namely to compensate the frequency change caused by the temperature change of the crystal, the load capacitance needs to be synchronously changed when the temperature changes; suppose load CLIs changed into CxWhen the frequency variation caused by the temperature variation of the crystal is just offset, the frequency variation has
From fL-fx=ΔfcCan obtain the productNamely, it is
Further, the relationship between the compensation capacitance and the temperature can be obtained as follows:
thus, by the above formula, it is possible to obtain a temperature coefficient a based on a certain value1、a2、a3And the required compensation capacitor C can be obtained at the current temperature Tx
Let the minimum unit capacitance be CunitThe number of capacitors to be compensated is num _ CunitThe following can be obtained:
wherein, Cx_minThe minimum value of the compensation capacitance required by the crystal due to temperature change is a constant;
according to the formula, after the temperature coefficient of a determined crystal is obtained, the size of the required compensation capacitor and the number of the required minimum unit capacitors can be obtained corresponding to each temperature value;
in summary, obtaining a temperature compensation table corresponding to the crystal according to the determined temperature coefficient includes:
obtaining the number of minimum unit capacitors required by the crystal at each temperature value according to the relationship between the determined temperature and the compensation capacitor required by the crystal, and further obtaining a temperature compensation table of the crystal; here, the temperature interval between each of the temperature values may be set as required, for example, the temperature interval may be 0.5 °; after the temperature compensation table is obtained in the automatic testing process before the terminal leaves a factory, the temperature compensation table can be directly applied in frequency fine adjustment in the subsequent terminal using process, namely, the terminal can directly obtain the corresponding required minimum unit capacitance number through the temperature compensation table according to the current temperature.
Further, before determining the temperature coefficient of the crystal, the method further comprises:
coarse tuning (Coarse tuning) a frequency of a crystal oscillator circuit to calibrate an initial frequency of the crystal oscillator circuit; the operation can be completed in an automatic test before the terminal containing the crystal oscillator circuit leaves a factory, particularly in a frequency coarse adjustment process of the automatic test;
wherein coarsely adjusting the frequency of the crystal oscillator circuit comprises:
calculating a reference clock error according to a carrier signal transmitted by a current transmitter TX, and calibrating the frequency of the crystal oscillator circuit by adjusting the size of a coarse tuning capacitor array to obtain a calibrated control word; preferably, it can be calibrated to an error of less than 1 ppm;
here, the method further includes: obtaining a correction coefficient k according to the ratio of the value of the calibrated control word to the value of the reference control word, namely the value of the calibrated control word/the value of the reference control word; the k is used as a correction coefficient when a nonlinear compensation table is obtained; the value of the reference control word can be set according to actual needs.
Further, after determining the temperature coefficient of the crystal and obtaining the temperature compensation table corresponding to the crystal according to the determined temperature coefficient, the method further includes:
initializing a digital baseband DBB AFC, calibrating the frequency to 26MHz, and acquiring an AFC control word initial value and a slope; and the AFC control word initial value and slope are used for rapidly searching the frequency when the terminal is started.
Step 102: acquiring a second control word according to the current AFC control word and the nonlinear compensation table;
this step can be implemented by a non-linear compensation circuit in the crystal oscillator circuit;
before this step, the method further comprises: acquiring the nonlinear compensation table according to the relationship between the AFC control word and the compensation capacitor required by the correction frequency-AFC control word curve;
if the value of the AFC control word is y and the pre-distorted control word is z, then:
if the f-y curve is linear, then fyAy + b; wherein a and b are constants which can be set according to actual conditions;
let fz=fyThe following can be obtained:after being corrected by the correction coefficient k, the following results are obtained:
according to the formula, the actually required compensation capacitor C 'can be obtained according to the determined AFC control word and the correction coefficient k'z
Let the minimum unit capacitance be CunitAnd the number of capacitors needing to be compensated is z, and the following can be obtained:
wherein, Cz_minComprises the following steps: for supplementingThe minimum value of the compensation capacitor required by the nonlinearity of the frequency-AFC control word curve is a constant;
in summary, the obtaining the nonlinear compensation table according to the relationship between the AFC control word and the compensation capacitor required for correcting the frequency-AFC control word curve includes:
determining the number of the minimum unit capacitors required corresponding to the values of different AFC control words in the crystal oscillator circuit according to the determined correction coefficient k, and further obtaining the nonlinear compensation table; the nonlinear compensation table can be directly applied to frequency fine adjustment in the subsequent terminal using process after being obtained in the automatic testing process before the terminal leaves a factory;
further, the obtaining a second control word according to the current AFC control word and the non-linear compensation table includes:
acquiring a second compensation capacitor corresponding to the AFC control word in a nonlinear compensation table in a lookup table mode according to the current AFC control word, and generating a second control word according to the second compensation capacitor;
the second control word is used for representing the number of minimum unit capacitances required by a corresponding AFC control word; the second compensation capacitance is represented by a minimum number of unit capacitances.
Further, the method further comprises: acquiring a second control word according to the current AFC control word and the relation between the AFC control word and a compensation capacitor required by correcting a frequency-AFC control word curve;
here, the relationship between the AFC control word and the compensation capacitance required to correct the frequency-AFC control word curve is:
the obtaining a second control word according to the current AFC control word and the relationship between the AFC control word and the compensation capacitor required for correcting the frequency-AFC control word curve includes:
according to the current AFC control word andobtaining a corrected frequency-AFC controls the Compensation capacitance C 'required by the word Curve'zAccording to the compensation capacitor C'zAnd acquiring the number of the corresponding minimum unit capacitors, and generating a second control word according to the acquired number of the minimum unit capacitors.
It should be noted that the operation sequences of step 101 and step 102 are not sequential, and may be processed in parallel.
Step 103: adjusting the capacitor array according to the first control word and the second control word to realize tuning of the frequency of the crystal oscillator circuit;
this step can be implemented by a tuning circuit in the crystal oscillator circuit;
the method specifically comprises the following steps: adding the first control word and the second control word to obtain a third control word, and adjusting the size of the capacitor array according to the third control word to realize tuning of the frequency of the crystal oscillator circuit; here, the third control word is used to characterize the number of minimum unit capacitances required to tune the crystal oscillator circuit.
Example two
FIG. 2 is a flow chart illustrating a tuning method of a two-crystal oscillator circuit according to an embodiment of the present invention; as shown in fig. 2, the tuning method of the crystal oscillator circuit according to the embodiment of the present invention includes:
step 201: acquiring a nonlinear compensation table according to the relationship between the AFC control word and a compensation capacitor required by a correction frequency-AFC control word curve;
determining a correction coefficient k, and determining the number of the required minimum unit capacitors corresponding to different AFC control word values in the crystal oscillator circuit according to the determined correction coefficient k to further obtain the nonlinear compensation table;
wherein the determining the correction coefficient k includes:
roughly calibrating the frequency of the crystal oscillator circuit by adjusting the size of the rough tuning capacitor array, and obtaining a calibrated control word; preferably, it can be calibrated to an error of less than 1 ppm;
here, the method further includes: obtaining a correction coefficient k according to the ratio of the value of the calibrated control word to the value of the reference control word; the value of the reference control word can be set according to actual needs; for certain radio frequency processing circuits/terminals, k is a constant.
Determining a number of required minimum unit capacitances for values of different AFC control words in a crystal oscillator circuit, comprising:
according toDetermining a magnitude C 'of a required compensation capacitance corresponding to values of different AFC control words in a crystal oscillator circuit'zAnd according toObtaining a corresponding number of required minimum unit capacitances;
wherein y is an AFC control word;is the series resonant frequency; cSIs the dynamic capacitance of the crystal; c0Is a static capacitance; c'zThe size of the compensation capacitance required for the corresponding AFC control word y; a. b is a constant which can be set according to actual conditions; cz_minComprises the following steps: the minimum value of the compensation capacitor required for compensating the nonlinearity of the frequency-AFC control word curve is a constant; cunitIs the minimum unit capacitance.
It should be noted that the operation corresponding to the nonlinear compensation table obtained in this step is only required to be performed when the tuning method of the crystal oscillator circuit of the present invention is performed for the first time or to be completed in an automatic test before the terminal including the crystal oscillator circuit leaves the factory, and the operation can be directly used subsequently.
Step 202: acquiring a temperature compensation table corresponding to the crystal according to the temperature coefficient of the current crystal;
here, the temperature coefficient of the crystal includes: first temperature coefficient a1A second temperature coefficient a2And a third temperature coefficient a3
The frequency-temperature characteristic of the crystal can be expressed as: Δ fc(T)=a3(T-T0)3+a2(T-T0)2+a1(T-T0);
Wherein, T0Is the inflection temperature of the crystal, about 25 °; the crystal may be AT cut;
Δfc(T) represents the amount of change in frequency at a temperature T.
Before this step, the method further comprises: determining the temperature coefficient of the crystal; it should be noted that the operation is only executed in the automatic test before the terminal leaves the factory;
the determining the temperature coefficient of the crystal comprises:
obtaining the frequency difference delta f (T) when the crystal temperature is T1 and T33)-f(T1) Obtaining the temperature coefficient of the crystal according to the corresponding relation between the frequency difference delta f and the temperature coefficient; wherein, (T2-Delta T)<T1<T2,T2<T3<(T2+ΔT),T1About 25 ° for the inflection temperature of the crystal; the corresponding relation between the frequency difference delta f and the temperature coefficient can be obtained by table lookup; for a given crystal, the corresponding temperature coefficient is constant.
In a crystal oscillator circuit, the input resistance of an amplifier needs to be matched with the series resonance impedance of a crystal, but the input impedance of the amplifier is usually high, so that the impedance of the amplifier and the impedance of the crystal may be mismatched during series resonance0The frequency response is worse than the series resonance, so a capacitor is usually connected in parallel across the crystal to lower C0The effect on the parallel resonant frequency; in parallel connection with a capacitor CLThe resonant frequency of the circuit can then be expressed as:
wherein, CSIs the dynamic capacitance of the crystal; l isSA dynamic inductance that is a crystal; c0Is a static capacitance; from series resonance frequency
Parallel resonant frequencyIt is possible to obtain,
according to the above formula, the load capacitance C can be adjustedLTo realize the change of the oscillation frequency of the crystal oscillator, namely to compensate the frequency change caused by the temperature change of the crystal, the load capacitance needs to be synchronously changed when the temperature changes; suppose load CLIs changed into CxWhen the frequency variation caused by the temperature variation of the crystal is just offset, the frequency variation has
From fL-fx=ΔfcCan obtain the productNamely, it is
Further, the relationship between the compensation capacitance and the temperature can be obtained as follows:
thus, by the above formula, it is possible to obtain a temperature coefficient a based on a certain value1、a2、a3And the required compensation capacitor C can be obtained at the current temperature Tx
Let the minimum unit capacitance be CunitThe number of capacitors to be compensated is num _ CunitThe following can be obtained:
wherein, Cx_minThe minimum value of the compensation capacitance required by the crystal due to temperature change is a constant;
according to the formula, after the temperature coefficient of a determined crystal is obtained, the size of the required compensation capacitor and the number of the required minimum unit capacitors can be obtained corresponding to each temperature value;
in summary, obtaining the temperature compensation table corresponding to the crystal according to the temperature coefficient of the current crystal includes:
according toObtaining the size C of the compensation capacitor needed by the crystal at each temperature valuexAnd obtaining a temperature compensation table of the crystal according to the obtained number of the corresponding minimum unit capacitors; here, the temperature interval between each of the temperature values may be set as needed, for example, the temperature interval may be 0.5 °.
It should be noted that the operation corresponding to the temperature compensation table obtained in this step is only required to be performed when the tuning method of the crystal oscillator circuit of the present invention is performed for the first time or to be completed in an automatic test before the terminal including the crystal oscillator circuit leaves the factory, and the operation can be directly applied subsequently.
Further, after this step, the method further comprises:
initializing a DBB AFC, calibrating the frequency to 26MHz, and acquiring an initial value of an AFC control word and a slope; the AFC control word initial value and slope are used for rapidly searching frequency when the terminal is started; note that this operation is only performed in an automated test before the terminal is shipped from the factory.
Step 203: acquiring a first control word according to the current digital voltage signal and a temperature compensation table;
here, the current digital voltage signal is obtained by converting an analog voltage signal input by the temperature sensing circuit through an analog-to-digital converter and inputting the analog voltage signal to the temperature compensation circuit; the analog voltage signal is generated by the temperature sensing circuit and changes along with the temperature change, namely the analog voltage signal is related to the temperature, namely the digital voltage signal is related to the temperature.
The method specifically comprises the following steps: determining a corresponding temperature value according to a current digital voltage signal, acquiring a first compensation capacitor corresponding to the temperature value in a temperature compensation table in a lookup table mode according to the temperature value, and generating a first control word according to the first compensation capacitor; the first control word is used for representing the size of a compensation capacitor required by the corresponding current digital voltage signal; the first compensation capacitor corresponding to the temperature value is the minimum unit capacitor number corresponding to the temperature value, namely the first compensation capacitor is represented by the minimum unit capacitor number.
Step 204: acquiring a second control word according to the current AFC control word and the nonlinear compensation table;
the method specifically comprises the following steps: acquiring a second compensation capacitor corresponding to the AFC control word in a nonlinear compensation table in a lookup table mode according to the current AFC control word, and generating a second control word according to the second compensation capacitor;
the second control word is used for representing the number of minimum unit capacitances required by a corresponding AFC control word; the second compensation capacitance is represented by a minimum number of unit capacitances.
It should be noted that the operation sequences of step 203 and step 204 are not sequential, and may be processed in parallel.
Step 205: adjusting the capacitor array according to the first control word and the second control word to realize tuning of the frequency of the crystal oscillator circuit;
the method specifically comprises the following steps: adding the first control word and the second control word to obtain a third control word, and adjusting the size of the capacitor array according to the third control word to realize tuning of the frequency of the crystal oscillator circuit; here, the third control word is used to characterize the number of minimum unit capacitances required to tune the crystal oscillator circuit.
EXAMPLE III
FIG. 3 is a schematic diagram of a circuit configuration of a crystal oscillator according to an embodiment of the present invention; as shown in fig. 3, the crystal oscillator circuit according to the embodiment of the present invention includes: a temperature compensation circuit 31, a nonlinear compensation circuit 32, and a tuning circuit 33; wherein,
the temperature compensation circuit 31 is configured to obtain a first control word according to the current digital voltage signal and the temperature compensation table;
the nonlinear compensation circuit 32 is configured to obtain a second control word according to the current AFC control word and the nonlinear compensation table;
the tuning circuit 33 is configured to adjust the capacitor array according to the first control word and the second control word, so as to tune the frequency of the crystal oscillator circuit.
Further, the current digital voltage signal is obtained by converting an input analog voltage signal and is related to temperature;
correspondingly, the crystal oscillator circuit further comprises an analog-to-digital converter 34 for converting the input analog voltage signal into a corresponding digital voltage signal.
Further, the crystal oscillator circuit further includes a processor 35, configured to determine a temperature coefficient of the crystal, and obtain a temperature compensation table corresponding to the crystal according to the determined temperature coefficient;
wherein the temperature coefficient of the crystal comprises: first temperature coefficient a1A second temperature coefficient a2And a third temperature coefficient a3
The frequency-temperature characteristic of the crystal can be expressed as: Δ fc(T)=a3(T-T0)3+a2(T-T0)2+a1(T-T0);
Wherein, T0Is the inflection temperature of the crystal, about 25 °; the crystal may be AT cut;
Δfc(T) represents the amount of change in frequency at a temperature T.
Further, the processor 35 is specifically configured to obtain a frequency difference Δ f ═ f (T3) when the crystal temperatures are T1 and T33)-f(T1) According to said frequency difference Δ f andobtaining the temperature coefficient of the crystal according to the corresponding relation of the temperature coefficients; wherein, (T2-Delta T)<T1<T2,T2<T3<(T2+ΔT),T1About 25 ° for the inflection temperature of the crystal; the corresponding relation between the frequency difference deltaf and the temperature coefficient can be obtained by looking up a table.
In a crystal oscillator circuit, the input resistance of an amplifier needs to be matched with the series resonance impedance of a crystal, but the input impedance of the amplifier is usually high, so that the impedance of the amplifier and the impedance of the crystal may be mismatched during series resonance0The frequency response is worse than the series resonance, so a capacitor is usually connected in parallel across the crystal to lower C0The effect on the parallel resonant frequency; in parallel connection with a capacitor CLThe resonant frequency of the circuit can then be expressed as:
wherein, CSIs the dynamic capacitance of the crystal; l isSA dynamic inductance that is a crystal; c0Is a static capacitance; from series resonance frequency
Parallel resonant frequencyIt is possible to obtain,
according to the above formula, the load capacitance C can be adjustedLTo realize the change of the oscillation frequency of the crystal oscillator, namely to compensate the frequency change caused by the temperature change of the crystal, the load capacitance needs to be synchronously changed when the temperature changes; suppose load CLIs changed into CxJust offset the temperature of the crystalFrequency variation caused by degree variation is as follows
From fL-fx=ΔfcCan obtain the productNamely, it is
Further, the relationship between the compensation capacitance and the temperature can be obtained as follows:
thus, by the above formula, it is possible to obtain a temperature coefficient a based on a certain value1、a2、a3And the required compensation capacitor C can be obtained at the current temperature Tx
Let the minimum unit capacitance be CunitThe number of capacitors to be compensated is num _ CunitThe following can be obtained:
wherein, Cx_minThe minimum value of the compensation capacitance required by the crystal due to temperature change is a constant;
according to the formula, after the temperature coefficient of a determined crystal is obtained, the size of the required compensation capacitor and the number of the required minimum unit capacitors can be obtained corresponding to each temperature value;
in summary, the obtaining, by the processor 35, a temperature compensation table corresponding to the crystal according to the determined temperature coefficient includes:
the processor 35 obtains the number of the minimum unit capacitance required by the crystal at each temperature value according to the relationship between the determined temperature and the compensation capacitance required by the crystal, and further obtains a temperature compensation table of the crystal; here, the temperature interval between each of the temperature values may be set as required, for example, the temperature interval may be 0.5 °; after the temperature compensation table is obtained in the automatic testing process before the terminal leaves a factory, the temperature compensation table can be directly applied in frequency fine adjustment in the subsequent terminal using process, namely, the terminal can directly obtain the corresponding required minimum unit capacitance number through the temperature compensation table according to the current temperature.
Further, the crystal oscillator circuit further includes a frequency coarse tuning circuit 36 for coarse tuning the frequency of the crystal oscillator circuit to calibrate the initial frequency of the crystal oscillator circuit; specifically, the method is used for calculating a reference clock error according to a carrier signal transmitted by a current transmitter TX, and calibrating the frequency of the crystal oscillator circuit by adjusting the size of an ATE Calibration capacitor array (ATE Calibration) to obtain a calibrated control word; preferably, the error is calibrated to less than 1 ppm.
Further, the frequency coarse tuning circuit 36 is further configured to obtain a correction coefficient k according to a ratio of the value of the calibrated control word to the value of the reference control word, that is, the value of the calibrated control word/the value of the reference control word; the k is used as a correction coefficient when a nonlinear compensation table is obtained; the value of the reference control word can be set according to actual needs.
Further, the temperature compensation circuit 31 is specifically configured to determine a corresponding temperature value according to the current digital voltage signal, obtain a first compensation capacitor corresponding to the temperature value in a temperature compensation table by using a lookup table according to the temperature value, and generate a first control word according to the first compensation capacitor; the first control word is used for representing the size of a compensation capacitor required by the corresponding current digital voltage signal; the first compensation capacitor corresponding to the temperature value is the minimum unit capacitor number corresponding to the temperature value, namely the first compensation capacitor is represented by the minimum unit capacitor number.
Further, the nonlinear compensation circuit 32 is specifically configured to obtain a second compensation capacitor corresponding to the AFC control word in a nonlinear compensation table by using a lookup table according to the current AFC control word, and generate a second control word according to the second compensation capacitor;
the second control word is used for representing the number of minimum unit capacitances required by a corresponding AFC control word; the second compensation capacitance is represented by a minimum number of unit capacitances.
Further, the processor 35 is further configured to obtain the non-linear compensation table according to a relationship between an AFC control word and a compensation capacitor required for correcting a frequency-AFC control word curve;
if the value of the AFC control word is y and the pre-distorted control word is z, then:
if the f-y curve is linear, then fyAy + b; wherein a and b are constants which can be set according to actual conditions;
let fz=fyThe following can be obtained:after being corrected by the correction coefficient k, the following results are obtained:
according to the formula, the actually required compensation capacitor C 'can be obtained according to the determined AFC control word and the correction coefficient k'z
Let the minimum unit capacitance be CunitAnd the number of capacitors needing to be compensated is z, and the following can be obtained:
wherein, Cz_minComprises the following steps: the minimum value of the compensation capacitor required for compensating the nonlinearity of the frequency-AFC control word curve is a constant;
in summary, the obtaining, by the processor 35, the nonlinear compensation table according to the relationship between the AFC control word and the compensation capacitor required for correcting the frequency-AFC control word curve includes:
the processor 35 determines the number of the minimum unit capacitors required corresponding to the values of different AFC control words in the crystal oscillator circuit according to the determined correction coefficient k, and further obtains the nonlinear compensation table; the nonlinear compensation table can be directly applied to frequency fine adjustment in the subsequent terminal using process after being obtained in the automatic testing process before the terminal leaves the factory.
Further, the nonlinear compensation circuit 32 is further configured to obtain a second control word according to the current AFC control word and a relationship between the AFC control word and a compensation capacitor required for correcting the frequency-AFC control word curve;
here, the relationship between the AFC control word and the compensation capacitance required to correct the frequency-AFC control word curve is:
the nonlinear compensation circuit 32 obtains a second control word according to the current AFC control word and a relationship between the AFC control word and a compensation capacitor required for correcting a frequency-AFC control word curve, and includes:
the non-linear compensation circuit 32 is based on the current AFC control word andobtaining a compensation capacitance C 'required for correcting a frequency-AFC control word curve'zAccording to the compensation capacitor C'zAnd acquiring the number of the corresponding minimum unit capacitors, and generating a second control word according to the acquired number of the minimum unit capacitors.
Further, the tuning circuit 33 is specifically configured to add the first control word and the second control word to obtain a third control word, and adjust the size of the capacitor array according to the third control word to tune the frequency of the crystal oscillator circuit;
here, the third control word is used to characterize the number of minimum unit capacitances required to tune the crystal oscillator circuit.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention.

Claims (8)

1. A method of tuning a crystal oscillator circuit, the method comprising:
acquiring a first control word for representing the size of a required compensation capacitor according to a current digital voltage signal and a temperature compensation table, wherein the temperature compensation table is determined at least based on at least one temperature coefficient of the crystal, and the temperature coefficient is determined based on the frequency difference of the crystal;
acquiring a second control word for representing the size of the required compensation capacitor according to the current Automatic Frequency Control (AFC) control word and the nonlinear compensation table;
and adjusting the capacitor array according to the first control word and the second control word to realize the tuning of the frequency of the crystal oscillator circuit.
2. The method of claim 1, wherein the current digital voltage signal is converted from an input analog voltage signal and is temperature dependent.
3. The method according to claim 1 or 2, wherein before the obtaining the first control word according to the current digital voltage signal and the temperature compensation table, the method further comprises:
and determining the temperature coefficient of the crystal, and acquiring a temperature compensation table corresponding to the crystal according to the determined temperature coefficient.
4. The method of claim 1 or 2, wherein the adjusting the capacitor array according to the first control word and the second control word to achieve the tuning of the frequency of the crystal oscillator circuit comprises:
and adding the first control word and the second control word to obtain a third control word, and adjusting the size of the capacitor array according to the third control word to realize the tuning of the frequency of the crystal oscillator circuit.
5. A crystal oscillator circuit, comprising: the temperature compensation circuit, the nonlinear compensation circuit and the tuning circuit; wherein,
the temperature compensation circuit is used for acquiring a first control word for representing the size of a required compensation capacitor according to a current digital voltage signal and a temperature compensation table, wherein the temperature compensation table is determined at least based on at least one temperature coefficient of the crystal, and the temperature coefficient is determined based on the frequency difference of the crystal;
the nonlinear compensation circuit is used for acquiring a second control word for representing the size of the required compensation capacitor according to the current AFC control word and the nonlinear compensation table;
and the tuning circuit is used for adjusting the capacitor array according to the first control word and the second control word so as to tune the frequency of the crystal oscillator circuit.
6. The crystal oscillator circuit of claim 5, wherein the current digital voltage signal is converted from an input analog voltage signal and is temperature dependent;
correspondingly, the crystal oscillator circuit further comprises an analog-to-digital converter for converting the input analog voltage signal into a corresponding digital voltage signal.
7. The crystal oscillator circuit of claim 5 or 6, further comprising a processor configured to determine a temperature coefficient of the crystal and obtain a temperature compensation table corresponding to the crystal based on the determined temperature coefficient.
8. The crystal oscillator circuit of claim 5, wherein the tuning circuit is configured to add the first control word and the second control word to obtain a third control word, and adjust a size of the capacitor array according to the third control word to tune a frequency of the crystal oscillator circuit.
CN201510369109.7A 2015-06-29 2015-06-29 A kind of crystal-oscillator circuit and its tuning methods Active CN106330134B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201510369109.7A CN106330134B (en) 2015-06-29 2015-06-29 A kind of crystal-oscillator circuit and its tuning methods
PCT/CN2016/074685 WO2017000571A1 (en) 2015-06-29 2016-02-26 Crystal oscillator circuit and method for controlling output signal amplitude thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510369109.7A CN106330134B (en) 2015-06-29 2015-06-29 A kind of crystal-oscillator circuit and its tuning methods

Publications (2)

Publication Number Publication Date
CN106330134A CN106330134A (en) 2017-01-11
CN106330134B true CN106330134B (en) 2019-10-22

Family

ID=57607752

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510369109.7A Active CN106330134B (en) 2015-06-29 2015-06-29 A kind of crystal-oscillator circuit and its tuning methods

Country Status (2)

Country Link
CN (1) CN106330134B (en)
WO (1) WO2017000571A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108092625B (en) * 2016-11-22 2020-06-09 深圳市中兴微电子技术有限公司 Signal amplitude calibration method and device
CN109617528B (en) * 2018-12-05 2023-03-21 深圳忆联信息系统有限公司 Method and system for correcting frequency of active oscillator
CN110401611B (en) * 2019-06-29 2021-12-07 西南电子技术研究所(中国电子科技集团公司第十研究所) Method for rapidly detecting CPFSK signal

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1238074A (en) * 1996-12-17 1999-12-08 摩托罗拉公司 Temperature compensation circuit for crystal oscillator
CN103001583A (en) * 2012-12-17 2013-03-27 华为技术有限公司 Temperature compensation method and crystal oscillator

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2376142Y (en) * 1999-01-04 2000-04-26 向明 Capacitance-resistance network voltage controlled sine-wave oscillator
US7292114B2 (en) * 2005-08-01 2007-11-06 Marvell World Trade Ltd. Low-noise high-stability crystal oscillator
JP2010130141A (en) * 2008-11-26 2010-06-10 Epson Toyocom Corp Voltage controlled temperature compensation piezoelectric oscillator
US8076913B2 (en) * 2008-12-22 2011-12-13 Mediatek Inc. Voltage converters and voltage generating methods for generating output voltage signals according to a pulse width modulation signal
CN103944514B (en) * 2014-04-28 2017-06-16 无锡中感微电子股份有限公司 Amplitude detection controls circuit and digitally controlled crystal oscillator system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1238074A (en) * 1996-12-17 1999-12-08 摩托罗拉公司 Temperature compensation circuit for crystal oscillator
CN103001583A (en) * 2012-12-17 2013-03-27 华为技术有限公司 Temperature compensation method and crystal oscillator

Also Published As

Publication number Publication date
WO2017000571A1 (en) 2017-01-05
CN106330134A (en) 2017-01-11

Similar Documents

Publication Publication Date Title
WO2016206384A1 (en) Crystal oscillator circuit, crystal oscillator circuit tuning method, and storage medium
EP2552025B1 (en) System and method for reducing temperature-dependent and process-dependent frequency variation of a crystal oscillator circuit
US7800457B2 (en) Self-calibrating temperature-compensated oscillator
US10763781B2 (en) System and method of crystal oscillator temperature compensation for operation in extended temperature range
CN107465393B (en) System and method for frequency compensation of real time clock system
US8896388B2 (en) Temperature-compensated crystal oscillator
US20100244945A1 (en) Calibration of Adjustable Filters
CN110034728B (en) System, apparatus and method for accurate measurement of off-chip temperature
US9013244B2 (en) Oscillating device, oscillating element and electronic apparatus
GB2482528A (en) Crystal reference oscillator for navigation applications
EP2284988A1 (en) Oscillator
CN106330134B (en) A kind of crystal-oscillator circuit and its tuning methods
US20070075797A1 (en) Method of manufacturing crystal oscillator and the crystal oscillator manufactured by the method
CN102185663A (en) Frequency calibration method and device
US10333525B1 (en) Digitally-based temperature compensation for a crystal oscillator
US10069498B2 (en) Simultaneous multi-effect oscillator compensation using piecewise interdependent polynomials
US6549055B2 (en) Method and apparatus for generating an input signal for a parameter sensitive circuit
US7576621B2 (en) Film bulk acoustic resonator calibration
JP2004336374A (en) Temperature compensation piezoelectric oscillator
US20240248161A1 (en) Peak detector calibration
EP3084965B1 (en) System and method for operating a mechanical resonator in an electronic oscillator
JP2011160038A (en) Method for manufacturing temperature compensation type oscillation circuit, and the temperature compensation type oscillation circuit
JP2013150120A (en) Crystal oscillator and electronic apparatus with the same
JP2008182406A (en) Am receiving circuit

Legal Events

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