A circuit parameter calibration method and negative feedback calibration loop

By initializing the control code and polarity in the control unit of the circuit calibration loop and automatically adjusting according to the error detection result, the problem that the calibration loop is affected by external factors is solved, and the calibration efficiency of circuit parameters is improved.

CN119472910BActive Publication Date: 2025-05-06SHANGHAI SHENGLIANKE SEMICONDUCTOR CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510046223.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-13
Publication Date
2025-05-06
Estimated Expiration
2045-01-13

AI Technical Summary

Technical Problem

In the prior art, the calibration loop is susceptible to external factors, resulting in a negative correlation between the adjustment process of the correction unit and the control parameters, which in turn affects the circuit calibration efficiency.

Method used

By initializing the control code in the control unit and assigning the polarity, adjusting the control code according to the comparison results of the error detection unit, and flipping the polarity when the control code exceeds the threshold, automatic adjustment of the polarity and the control code is achieved.

Benefits of technology

The calibration loop is inefficient due to external factors, and the rapid and accurate calibration of circuit parameters is achieved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119472910B_ABST
    Figure CN119472910B_ABST
Patent Text Reader

Abstract

The invention discloses a circuit parameter calibration method and a negative feedback calibration loop, the circuit parameter calibration method comprising: step 1, initializing a control code, and assigning a polarity to a first polarity value; step 2, controlling a duty cycle adjustment unit to adjust the duty cycle based on the control code, and obtaining a comparison result output by an error detection unit; step 3, adjusting the control code based on the polarity and whether the comparison result is equal to a preset comparison value; step 4, judging whether the adjusted control code exceeds a control code threshold, if the control code does not overflow, and jumping to step 6; step 5, if the control code exceeds the control code threshold, judging that the polarity is wrong, and flipping the polarity to a second polarity value, and jumping to step 2; step 6, obtaining a comparison result according to the adjusted control code, and judging whether the loop is locked according to the comparison result. The invention solves the problem that it is difficult to accurately calibrate the circuit control parameters in the existing calibration loop, and improves the calibration efficiency of the circuit control parameters.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of integrated circuits, and in particular to a circuit parameter calibration method and a negative feedback calibration loop. Background Art

[0002] In order to achieve accurate calibration of circuit parameters, a calibration loop is usually introduced into the circuit. The calibration loop usually includes an error detection unit and a correction unit. The error detection unit is used to detect the error of the circuit and determine whether the error is positive or negative; the correction unit is used to gradually reduce the error by adjusting under the action of the control parameter until the error is corrected to a specified range. Among them, the adjustment process of the correction unit should be positively correlated with the control parameter, that is, increasing the control parameter will lead to an increase in the error, and reducing the control parameter will lead to a decrease in the error.

[0003] In the prior art, due to the influence of external factors such as the wiring sequence, a negative correlation may occur between the adjustment process of the correction unit and the control parameters. In this case, the judgment of the error change direction is prone to error, which in turn affects the circuit calibration efficiency and makes it difficult to quickly complete the calibration of the circuit control parameters.

[0004] Based on this, a new technical solution is needed. Summary of the invention

[0005] In view of this, an embodiment of the present invention provides a circuit parameter calibration method and a negative feedback calibration loop, so as to at least solve the problem that the existing calibration loop is affected by external factors, making it difficult to accurately calibrate the circuit control parameters.

[0006] The embodiment of the present invention provides the following technical solutions:

[0007] An embodiment of the present invention provides a circuit parameter calibration method, which is applied to a control unit connected to a duty cycle adjustment unit and an error detection unit in a negative feedback calibration loop. The circuit parameter calibration method includes:

[0008] Step 1, initializing the control code, and assigning the polarity to a first polarity value;

[0009] Step 2: controlling the duty cycle adjustment unit to adjust the duty cycle based on the control code, and obtaining a comparison result output by the error detection unit;

[0010] Step 3: adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value;

[0011] Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value, and jump to step 6;

[0012] Step 5: If the control code exceeds the control code threshold, it is determined that the polarity assignment is wrong, and the polarity is flipped to a second polarity value, and the process jumps to step 2;

[0013] Step 6: Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed.

[0014] Further, adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value includes:

[0015] The assignment of the polarity is determined, and the control code is adjusted according to the assignment of the polarity and whether the comparison result is equal to the preset comparison value.

[0016] Further, when the polarity is the first polarity value,

[0017] When the comparison result is equal to the preset comparison value, the control code is increased;

[0018] When the comparison result is not equal to the preset comparison value, the control code is reduced.

[0019] Further, when the polarity is the second polarity value,

[0020] When the comparison result is equal to the preset comparison value, reducing the control code;

[0021] When the comparison result is not equal to the preset comparison value, the control code is increased.

[0022] Further, after the polarity is flipped to the second polarity value, before jumping to step 2, the control code is initialized.

[0023] Furthermore, after jumping to execute step 2 to step 4, if the adjusted control code exceeds the control code threshold, an error occurs in the calibration, and the calibration is terminated at this time.

[0024] Further, judging whether the loop is locked according to the comparison result includes:

[0025] When the comparison result corresponding to the adjusted control code and the comparison result corresponding to the control code before adjustment switch between being equal to or not equal to a preset comparison value, it is considered that the loop is locked.

[0026] The present invention also provides a negative feedback calibration loop, comprising:

[0027] A duty cycle adjustment unit, wherein the duty cycle adjustment unit is used to adjust the duty cycle;

[0028] an error detection unit, the error detection unit being used to compare the duty cycle with a target value and output a comparison result;

[0029] A control unit, the control unit being configured to perform the following steps:

[0030] Step 1, initializing the control code, and assigning the polarity to a first polarity value;

[0031] Step 2: controlling the duty cycle adjustment unit to adjust the duty cycle based on the control code, and obtaining a comparison result output by the error detection unit;

[0032] Step 3: adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value;

[0033] Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value, and jump to step 6;

[0034] Step 5: If the control code exceeds the control code threshold, it is determined that the polarity assignment is wrong, and the polarity is flipped to a second polarity value, and the process jumps to step 2;

[0035] Step 6: Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed.

[0036] Further, the error detection unit includes a low-pass filter and a comparator;

[0037] The input end of the low-pass filter is connected to the duty cycle adjustment unit, the output end of the low-pass filter is connected to the input end of the comparator, and the output end of the comparator is connected to the control unit.

[0038] Furthermore, the duty cycle adjustment unit is a clock duty cycle adjustment circuit, and the control unit is a digital control logic module.

[0039] Compared with the prior art, the at least one technical solution adopted in the embodiment of the present invention can achieve the following beneficial effects:

[0040] A circuit parameter calibration method of the present invention adjusts a control code according to a comparison result output by an error detection unit when the polarity is assigned to a first polarity value, and when the adjusted control code exceeds a control code threshold, determines that the polarity is assigned incorrectly and flips the polarity to a second polarity value, and finally adjusts the control code according to the comparison result output by the error detection unit and the second polarity value when the polarity is assigned to a second polarity value, thereby realizing automatic flipping of the polarity and automatic adjustment of the control code, solving the problem that the existing calibration loop is affected by external factors, making it difficult to accurately calibrate the circuit control parameters, and improving the calibration efficiency of the circuit control parameters. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0042] Figure 1 A structural block diagram of a negative feedback calibration loop according to an embodiment of the present invention;

[0043] Figure 2 A control logic diagram of a negative feedback calibration loop according to an embodiment of the present invention;

[0044] Figure 3 4 is a waveform diagram of a negative feedback calibration loop according to an embodiment of the present invention.

[0045] The accompanying drawings of the present invention are as follows:

[0046] 10. Control unit; 20. Duty cycle adjustment unit; 30. Error detection unit; 31. Low-pass filter; 32. Comparator. DETAILED DESCRIPTION

[0047] The embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0048] The following describes the implementation methods of the present application through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in this specification. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. The present application can also be implemented or applied through other different specific implementation methods, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present application. It should be noted that, in the absence of conflict, the following embodiments and the features in the embodiments can be combined with each other. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work belong to the scope of protection of the present application.

[0049] It should be noted that various aspects of the embodiments within the scope of the appended claims are described below. It should be apparent that the aspects described herein can be embodied in a wide variety of forms, and any specific structure and / or function described herein is merely illustrative. Based on the present application, it should be understood by those skilled in the art that an aspect described herein can be implemented independently of any other aspect, and two or more of these aspects can be combined in various ways. For example, any number and aspect described herein can be used to implement the device and / or practice the method. In addition, other structures and / or functionalities other than one or more of the aspects described herein can be used to implement this device and / or practice this method.

[0050] It should also be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present application. The drawings only show components related to the present application rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0051] Additionally, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the examples can be practiced without these specific details.

[0052] In order to realize the automatic calibration of circuit parameters, a negative feedback calibration loop needs to be introduced into the circuit. The calibration loop usually consists of three parts: the correction unit, the error detection unit and the control logic unit.

[0053] The general circuit calibration method process is as follows: after the correction unit adjusts the duty cycle, the error detection unit determines whether the current error is positive or negative. If the current error is positive, the calibration logic unit reduces the control parameter value, and the error is reduced through the correction unit until it reaches 0; if the current error is negative, the calibration logic unit increases the control parameter value, and the error is increased through the correction unit until it reaches 0. Among them, the implementation of this negative feedback calibration process requires ensuring that there is a positive correlation between the correction unit and the control parameter, that is, the control parameter increases and the correction unit increases the error. If there is a negative correlation between the correction unit and the control parameter, that is, the control parameter increases, the correction unit will reduce the error, so that the direction of error change is reversed, and the calibration loop cannot converge. In actual circuits, due to other reasons such as the wiring sequence, it is very easy to make mistakes in the judgment of the direction of error change.

[0054] Based on such background, the present invention proposes a polarity adaptive circuit calibration method, which automatically determines the polarity of a control parameter in a control logic unit, realizes automatic calibration of the circuit, and improves the efficiency of circuit parameter calibration.

[0055] Based on this, this specification embodiment proposes a processing solution: Figure 2 As shown, a circuit parameter calibration method of the present invention, after the initial polarity and adjustment of the control code, if the control code exceeds the control code threshold, it can be judged that the polarity is wrong. At this time, the control unit 10 can automatically flip the polarity and initialize the control code to achieve automatic adjustment of the polarity and automatically adjust the duty cycle through the control code to increase the calibration rate, thereby solving the problem that the existing calibration loop is affected by external factors, making it difficult to accurately calibrate the circuit control parameters.

[0056] The technical solutions provided by various embodiments of the present application are described below in conjunction with the accompanying drawings.

[0057] Example 1

[0058] like Figure 1~Figure 2 As shown, a circuit parameter calibration method of the present invention is applied to a control unit 10 connected to a duty cycle adjustment unit 20 and an error detection unit 30 in a negative feedback calibration loop.

[0059] Among them, the output end of the control unit 10 is connected to the input end of the duty cycle adjustment unit 20 to control the duty cycle adjustment unit 20 to adjust the duty cycle through the control code, and the output end of the duty cycle adjustment unit 20 is connected to the input end of the error detection unit 30 to send the adjusted duty cycle to the error detection unit 30; the output end of the error detection unit 30 is connected to the input end of the control unit 10 to compare the adjusted duty cycle with the target value of the duty cycle and output the comparison result, which is 1 or 0.

[0060] For example, when the duty cycle is greater than the target value of the duty cycle, the error detection unit 30 outputs 1, and when the target value of the duty cycle is less than the target value of the duty cycle, the error detection unit 30 outputs 0.

[0061] The present invention mainly improves the control logic of the control unit 10. The specific steps of the circuit parameter calibration method of the present invention are as follows:

[0062] Step 1: Initialize the control code and assign the polarity to a first polarity value.

[0063] The control code is sent to the duty cycle adjustment unit 20, so that the duty cycle adjustment unit 20 can adjust the duty cycle according to the control code.

[0064] For example, when the control code is increased, the duty cycle adjustment unit 20 increases the duty cycle; when the duty cycle is decreased, the duty cycle adjustment unit 20 decreases the duty cycle.

[0065] Among them, the first polarity value can be the default correct value of the polarity, that is, when there is no problem with the wiring sequence, adjusting the control code according to the first polarity value can make the duty cycle gradually converge to the target value; when there is a problem with the wiring sequence, although the first polarity value is the default correct value, adjusting the control code will cause the duty cycle to gradually diverge.

[0066] Step 2: Control the duty cycle adjustment unit 20 to adjust the duty cycle based on the control code, and obtain the comparison result output by the error detection unit 30.

[0067] After the duty cycle adjustment unit 20 obtains the control code transmitted by the control unit 10, the duty cycle adjustment unit 20 can adjust the duty cycle according to the control code. For example, when the control code is increased, the duty cycle adjustment unit 20 can increase the duty cycle; when the control code is reduced, the duty cycle adjustment unit 20 can reduce the duty cycle.

[0068] After obtaining the duty cycle transmitted by the duty cycle adjustment unit 20 , the error detection unit 30 determines the duty cycle and compares it with the target value (the target value to which the duty cycle needs to be adjusted) through the comparator 32 , and outputs the comparison result, that is, the comparison result is usually output as 1 or 0.

[0069] Among them, since the comparator 32 can only output 1 or 0, the comparison result output by the error detection unit 30 is also 1 or 0. For example, when the output result of the comparator 32 is 1, it means that the adjusted duty cycle is less than the target value. When the output result of the comparator 32 is 0, it means that the adjusted duty cycle is greater than the target value.

[0070] This step is to control the duty cycle adjustment unit 20 to adjust the duty cycle through the control code, and obtain the size of the adjusted duty cycle and the target value to facilitate further judgment later.

[0071] Step 3: Adjust the control code based on the polarity assignment and whether the comparison result is equal to a preset comparison value.

[0072] The preset comparison value is a preset value, which may be 1 or 0, and is used for comparison according to the result output by the comparator 32 in the error detection unit 30 .

[0073] For example, when the result output by the comparator 32 is equal to 1, it can be considered that the duty cycle adjusted by the duty cycle adjustment unit 20 is less than the target value. At this time, the control code can be increased or decreased according to the polarity assigned different values, so that the duty cycle adjustment unit 20 can increase or decrease the duty cycle, so that the adjusted duty cycle converges to the target value.

[0074] Before adjusting the control code, it is necessary to first determine the polarity assignment, and adjust the control code according to the polarity assignment and whether the comparison result is equal to a preset comparison value.

[0075] Specifically, when the control unit 10 responds to the same comparison result, the change direction of the control code is different due to the different polarity values, and the change direction of the control code includes increase or decrease.

[0076] After obtaining the comparison result, the control unit 10 of the present application can adjust the change direction of the control code according to the polarity so that the duty cycle is close to the target value. The specific change process is as follows:

[0077] (1) When the polarity is assigned a first polarity value, based on the polarity assignment, adjusting the control code according to whether the comparison result is equal to a preset comparison value includes: when the comparison result is equal to the preset comparison value, increasing the control code; when the comparison result is not equal to the preset comparison value, decreasing the control code.

[0078] (2) When the polarity is the second polarity value, based on the assignment of the polarity, adjusting the control code according to whether the comparison result is equal to the preset comparison value includes: when the comparison result is equal to the preset comparison value, reducing the control code; when the comparison result is not equal to the preset comparison value, increasing the control code.

[0079] In this step, when the polarity is assigned different polarity values, the change direction of the control code is also different, so that the control code is automatically adjusted for different polarities after the polarity is flipped.

[0080] Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value and jump to step 6.

[0081] Among them, under the first polarity value, if the comparison result is always equal to 1 or 0, the control unit 10 always adjusts the control code in a change direction (always increasing or decreasing). If the control code does not overflow after being adjusted multiple times, it means that the control code adjustment direction is correct, and step 6 is executed to continue adjusting the control code until the circuit is adjusted to loop lock.

[0082] Step 5: If the control code exceeds the control code threshold, determine that the polarity is wrong, flip the polarity to a second polarity value, and jump to step 2.

[0083] Under the first polarity value, if the comparison result is always equal to 1 or 0, and the control code overflows (exceeds the maximum value or minimum value) after being adjusted multiple times, it means that the control code is adjusted in the wrong direction, and the polarity needs to be flipped to the second polarity value and jump to step 2.

[0084] After the polarity is flipped to the second polarity value, before jumping to step 2, the control code needs to be initialized so as to adjust the duty cycle to be close to the target value.

[0085] In some of the embodiments, after the polarity is flipped to the second polarity value and the execution of step 2 to step 4 is jumped, if the adjusted control code still exceeds the control code threshold, it is considered that the calibration is wrong and the calibration is terminated.

[0086] For example, Figure 2 As shown, when the comparison result output by the error detection unit 30 is not equal to 1, if the polarity is the first polarity value, the control code is reduced to reduce the duty cycle. After reducing the duty cycle for multiple times, if the duty cycle adjusted by the duty cycle adjustment unit 20 cannot be close to the target value or the comparison result output by the error detection unit 30 remains unchanged and the control code overflows, it means that the polarity of the negative feedback calibration loop is flipped due to problems such as the wiring sequence, and reducing the duty cycle cannot converge the duty cycle to the target value, so the polarity needs to be flipped to the second polarity value; after flipping the polarity to the second polarity value and initializing the control code, since the comparison result is not equal to 1, the control code is increased to increase the duty cycle until the comparison result output by the error detection unit 30 is equal to 1.

[0087] Figure 3 The waveform diagram of the clock duty cycle calibration loop is given. Initially, the polarity is 0, the comparison result din is greater than 0, and the duty cycle control code increases continuously, causing the clock duty cycle to deviate from the target value until the control code overflows. Then the control code polarity automatically changes to 1. When the comparison result din is greater than 0, the duty cycle control code decreases continuously, causing the clock duty cycle to approach the target value continuously until the calibration loop converges.

[0088] When a polarity error is detected through steps 4 and 5, the control unit 10 automatically flips the polarity to readjust the adjustment direction of the control code, thereby solving the problem in the prior art that the duty cycle cannot be adjusted to the target value after the polarity flip, and improving the calibration efficiency of the negative feedback calibration loop.

[0089] Step 6: Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed.

[0090] Specifically, when the comparison result corresponding to the adjusted control code and the comparison result corresponding to the control code before adjustment switch between being equal to or not equal to a preset comparison value, it is considered that the loop is locked.

[0091] When the comparison result before adjusting the control code is equal to 1 and the comparison result after adjusting the control code is not equal to 1 and this happens repeatedly, it is considered that the duty cycle adjusted by the duty cycle adjustment unit 20 is close to the target value, and the duty cycle calibration is completed.

[0092] A circuit parameter calibration method according to an embodiment of the present invention, under the premise that the polarity is assigned to a first polarity value, by adjusting the control code according to the first control logic (increasing the control code when the preset comparison value is equal to 1, and reducing the control code when the preset comparison value is not equal to 1) when the duty cycle cannot converge to the target value, flipping the polarity to the second polarity value, and after initializing the control code, adjusting the control code according to the second control logic (reducing the control code when the preset comparison value is equal to 1, and increasing the control code when the preset comparison value is not equal to 1), thereby achieving the duty cycle convergence to the target value.

[0093] The circuit calibration method of the present invention can automatically determine the polarity of the control parameter in the control unit, thereby realizing automatic calibration of the circuit and greatly improving the calibration efficiency.

[0094] Example 2

[0095] like Figure 1 As shown, the embodiment of the present invention further provides a negative feedback calibration loop, including a duty cycle adjustment unit 20, an error detection unit 30 and a control unit 10. The duty cycle adjustment unit 20 is used to adjust the duty cycle; the error detection unit 30 is used to compare the duty cycle with the target value and output the comparison result; the control unit 10 is configured to perform the following steps:

[0096] Step 1, initializing the control code, and assigning the polarity to a first polarity value;

[0097] Step 2: controlling the duty cycle adjustment unit 20 to adjust the duty cycle based on the control code, and obtaining a comparison result output by the error detection unit 30;

[0098] Step 3: adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value;

[0099] Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value, and jump to step 6;

[0100] Step 5: If the control code exceeds the control code threshold, it is determined that the polarity assignment is wrong, and the polarity is flipped to a second polarity value, and the process jumps to step 2;

[0101] Step 6: Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed.

[0102] The duty cycle adjustment unit 20 is a clock duty cycle adjustment circuit, and the control unit 10 is a digital control logic module.

[0103] Further, the error detection unit 30 includes a low-pass filter 31 and a comparator 32;

[0104] An input end of the low-pass filter 31 is connected to the duty cycle adjustment unit 20 , an output end of the low-pass filter 31 is connected to an input end of the comparator 32 , and an output end of the comparator 32 is connected to the control unit 10 .

[0105] like Figure 1 A specific implementation of the present invention is given, and the polarity adaptive circuit calibration method proposed in the present invention is used to realize automatic calibration of the clock duty cycle. It should be pointed out that the present invention should not be limited to the clock duty cycle calibration circuit in the specific implementation, but should be applicable to all negative feedback calibration loops in the circuit.

[0106] like Figure 1 As shown, the clock duty cycle calibration circuit includes a clock duty cycle adjustment unit 20, an error detection unit 30 (including a low-pass filter 31 and a comparator 32), and a control logic unit (digital control logic). The differential clocks clkp and clkn are input into the clock duty cycle adjustment unit 20. After the clock duty cycle is changed, the clock duty cycle is converted into a DC level through the low-pass filter 31, and the comparison result din is obtained through the comparator 32. The digital control logic updates the control code of the clock duty cycle through the comparison result din, and the clock duty cycle adjustment unit 20 changes the clock duty cycle under the control of the control code, thereby realizing the negative feedback calibration of the duty cycle.

[0107] Control logic such as Figure 2As shown, the control code of the clock duty cycle is initially set, and the polarity is set to 0, and then the control code is increased or decreased according to the comparison result din until the loop is locked, and the calibration of the clock duty cycle is completed. If the control code overflows, it means that the polarity of the control parameter is reversed, and the polarity is changed to 1, and then the control code is decreased or increased according to the comparison result din until the loop is locked, and the calibration of the clock duty cycle is completed. Among them, when the polarity of the control code is different, for the same comparison result din, the change direction of the control code is opposite.

[0108] In this specification, the same or similar parts between the various embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the product embodiment described later, since it corresponds to the method, the description is relatively simple, and the relevant parts can be referred to the partial description of the system embodiment.

[0109] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.

Claims

1. A circuit parameter calibration method, characterized in that: A control unit is applied to a negative feedback calibration loop and is connected to a duty cycle adjustment unit and an error detection unit respectively. The circuit parameter calibration method includes: Step 1, initializing the control code, and assigning the polarity to a first polarity value; Step 2: controlling the duty cycle adjustment unit to adjust the duty cycle based on the control code, and obtaining a comparison result output by the error detection unit; Step 3: adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value; Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value, and jump to step 6; Step 5: If the control code exceeds the control code threshold, it is determined that the polarity assignment is wrong, and the polarity is flipped to a second polarity value, and the process jumps to step 2; Step 6. Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed, wherein determining whether the loop is locked includes: when the comparison result corresponding to the adjusted control code and the comparison result corresponding to the control code before adjustment switch between being equal to or not equal to a preset comparison value, the loop is considered to be locked.

2. The circuit parameter calibration method according to claim 1, characterized in that: Adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value includes: The assignment of the polarity is determined, and the control code is adjusted according to the assignment of the polarity and whether the comparison result is equal to the preset comparison value.

3. The circuit parameter calibration method according to claim 2, characterized in that: When the polarity is the first polarity value, When the comparison result is equal to the preset comparison value, the control code is increased; When the comparison result is not equal to the preset comparison value, the control code is reduced.

4. The circuit parameter calibration method according to claim 2, characterized in that: When the polarity is the second polarity value, When the comparison result is equal to the preset comparison value, reducing the control code; When the comparison result is not equal to the preset comparison value, the control code is increased.

5. The circuit parameter calibration method according to claim 1, characterized in that: After the polarity is flipped to the second polarity value, before jumping to step 2, the control code is initialized.

6. The circuit parameter calibration method according to any one of claims 1 or 5, characterized in that: After jumping to execute step 2 to step 4, if the adjusted control code exceeds the control code threshold, an error occurs in the calibration, and the calibration is terminated at this time.

7. A negative feedback calibration loop, characterized in that: include: A duty cycle adjustment unit, wherein the duty cycle adjustment unit is used to adjust the duty cycle; an error detection unit, the error detection unit being used to compare the duty cycle with a target value and output a comparison result; A control unit, the control unit being configured to perform the following steps: Step 1, initializing the control code, and assigning the polarity to a first polarity value; Step 2: controlling the duty cycle adjustment unit to adjust the duty cycle based on the control code, and obtaining a comparison result output by the error detection unit; Step 3: adjusting the control code based on the assignment of the polarity and whether the comparison result is equal to a preset comparison value; Step 4: determine whether the adjusted control code exceeds the control code threshold; if the control code does not overflow, retain the polarity as the first polarity value, and jump to step 6; Step 5: If the control code exceeds the control code threshold, it is determined that the polarity assignment is wrong, and the polarity is flipped to a second polarity value, and the process jumps to step 2; Step 6. Obtain the comparison result according to the adjusted control code, and determine whether the loop is locked according to the comparison result. If the loop is not locked, jump to step 2; if the loop is locked, the calibration is completed, wherein determining whether the loop is locked includes: when the comparison result corresponding to the adjusted control code and the comparison result corresponding to the control code before adjustment switch between being equal to or not equal to a preset comparison value, the loop is considered to be locked.

8. The negative feedback calibration loop according to claim 7, characterized in that: The error detection unit includes a low-pass filter and a comparator; The input end of the low-pass filter is connected to the duty cycle adjustment unit, the output end of the low-pass filter is connected to the input end of the comparator, and the output end of the comparator is connected to the control unit.

9. The negative feedback calibration loop according to claim 7, characterized in that: The duty cycle adjustment unit is a clock duty cycle adjustment circuit, and the control unit is a digital control logic module.

Citation Information

Patent Citations

  • Reference clock calibration circuit, calibration method and reference clock frequency multiplier

    CN117040494A

  • Calibration method of electric curtain

    CN118963193A