Clock frequency calibration method, system, device, medium and program product
By establishing mapping relationships that affect parameters and weight adjustments, the calibration of clock frequency is achieved, solving the problems of difficult and cost of chip design, and improving the accuracy and accuracy of clock frequency.
Patent Information
- Application Number
- CN202411045178.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-12-03
AI Technical Summary
The prior art sets an accurate clock in the chip to ensure the accuracy of the clock frequency, resulting in high chip design and high cost.
By establishing a mapping relationship based on the current and historical parameter values of the influence parameters of the clock frequency, calculating the current error value and adjusting the target error value according to the weight, and calibrating the clock frequency to reduce the clock frequency error under various environmental factors.
The accuracy and accuracy of clock frequency is achieved, reducing the difficulty and cost of chip design, and reducing the frequency error range.
Smart Images

Figure CN119065453A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of clock calibration, and in particular to a clock frequency calibration method, system, device, medium and program product. Background Art
[0002] The frequency error of the RCO (RC Oscillator) clock in the SOC (System on Chip) can reach ±20% under the influence of various environmental factors, which is a relatively large error. The existing technology usually sets a precise clock in the chip to ensure the accuracy of the clock frequency, but this method increases the difficulty and cost of chip design. Summary of the invention
[0003] The technical problem to be solved by the present disclosure is to overcome the defects of setting a precise clock in the chip to ensure the accuracy of the clock frequency in the prior art, which leads to difficulty in chip design and high chip design cost, and to provide a clock frequency calibration method, system, device, medium and program product.
[0004] The present invention solves the above technical problems through the following technical solutions:
[0005] The present disclosure provides a clock frequency calibration method, the calibration method comprising:
[0006] Based on current parameter values of at least two influencing parameters of the clock frequency and a mapping relationship corresponding to each of the influencing parameters, obtaining a current error value of the clock frequency corresponding to the current parameter value of each of the influencing parameters;
[0007] The mapping relationship corresponding to each of the influencing parameters is established based on a plurality of groups of corresponding historical parameter values of the influencing parameters and a first historical error value of the clock frequency;
[0008] Based on each of the current error values, obtaining a target error value of the clock frequency;
[0009] The standard frequency value of the clock frequency is calibrated based on the target error value to obtain a target frequency value.
[0010] Preferably, the step of obtaining the target error value of the clock frequency based on each of the current error values comprises:
[0011] The sum of each of the current error values is taken as the target error value.
[0012] Preferably, the step of obtaining the target error value of the clock frequency based on each of the current error values comprises:
[0013] Obtaining a weight corresponding to each of the current error values;
[0014] Based on each of the current error values and the corresponding weight, the target error value is obtained.
[0015] Preferably, the step of obtaining the weight corresponding to each current error value comprises:
[0016] Obtaining a difference value between the current parameter value and the standard parameter value of each of the influencing parameters;
[0017] Based on the gap value, determine the weight corresponding to each of the current error values;
[0018] The weight is positively correlated with the gap value.
[0019] Preferably, the gap value includes a ratio or a difference.
[0020] Preferably, the step of obtaining the target error value based on each of the current error values and the corresponding weight comprises:
[0021] Obtaining the product of each current error value and the corresponding weight;
[0022] The sum of each of the products is taken as the target error value.
[0023] Preferably, the first historical error value corresponding to each of the historical parameter values of each of the influencing parameters is an average value of a plurality of second historical error values corresponding to each of the historical parameter values of each of the influencing parameters;
[0024] The second historical error value is a difference between a historical frequency value of the clock frequency corresponding to the historical parameter value and the standard frequency value;
[0025] and / or,
[0026] The step of calibrating the standard frequency value of the clock frequency based on the target error value to obtain the target frequency value comprises:
[0027] Taking the sum of the target error value and the standard frequency value as the target frequency value;
[0028] and / or,
[0029] The influencing parameters of the clock frequency include at least two of ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and an operating voltage of a chip to which the clock frequency belongs.
[0030] The present disclosure also provides a clock frequency calibration system, the calibration system comprising:
[0031] A current error value acquisition module, configured to obtain a current error value of the clock frequency corresponding to the current parameter value of each influencing parameter based on current parameter values of at least two influencing parameters of the clock frequency and a mapping relationship corresponding to each of the influencing parameters;
[0032] The mapping relationship corresponding to each of the influencing parameters is established based on a plurality of groups of corresponding historical parameter values of the influencing parameters and a first historical error value of the clock frequency;
[0033] A target error value acquisition module, used to obtain a target error value of the clock frequency based on each of the current error values;
[0034] The calibration module is used to calibrate the standard frequency value of the clock frequency based on the target error value to obtain a target frequency value.
[0035] Preferably, the target error value acquisition module includes:
[0036] The first error value obtaining unit is used to take the sum of each of the current error values as the target error value.
[0037] Preferably, the target error value acquisition module includes:
[0038] A weight acquisition unit, used to acquire a weight corresponding to each of the current error values;
[0039] The second error value acquisition unit is used to obtain the target error value based on each of the current error values and the corresponding weight.
[0040] Preferably, the weight acquisition unit includes:
[0041] A gap value acquisition subunit, used to acquire a gap value between the current parameter value and the standard parameter value of each of the influencing parameters;
[0042] A weight acquisition subunit, used to determine the weight corresponding to each of the current error values based on the gap value;
[0043] The weight is positively correlated with the gap value.
[0044] Preferably, the gap value includes a ratio or a difference.
[0045] Preferably, the second error value obtaining unit includes:
[0046] A product acquisition subunit, used to acquire the product of each current error value and the corresponding weight;
[0047] The error value acquisition subunit is used to take the sum of each of the products as the target error value.
[0048] Preferably, the first historical error value corresponding to each of the historical parameter values of each of the influencing parameters is an average value of a plurality of second historical error values corresponding to each of the historical parameter values of each of the influencing parameters;
[0049] The second historical error value is a difference between a historical frequency value of the clock frequency corresponding to the historical parameter value and the standard frequency value;
[0050] and / or,
[0051] The calibration module is further used to take the sum of the target error value and the standard frequency value as the target frequency value;
[0052] and / or,
[0053] The influencing parameters of the clock frequency include at least two of ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and an operating voltage of a chip to which the clock frequency belongs.
[0054] The present disclosure also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and used to run on the processor, and the processor implements the above-mentioned clock frequency calibration method when executing the computer program.
[0055] The present disclosure also provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the clock frequency calibration method described above is implemented.
[0056] The present disclosure also provides a computer program product, including a computer program, and when the computer program is executed by a processor, the clock frequency calibration method as described above is implemented.
[0057] The present disclosure also provides a chip having a computer program stored thereon, and when the computer program is executed by the chip, the clock frequency calibration method as described above is implemented.
[0058] The present disclosure also provides a chip module, which is applied to electronic equipment, including a transceiver component and a chip, wherein the chip is used to implement the clock frequency calibration method as described above.
[0059] On the basis of being in accordance with the common sense in the art, the above-mentioned preferred conditions can be arbitrarily combined to obtain the preferred embodiments of the present disclosure.
[0060] The positive and progressive effects of this disclosure are:
[0061] The present invention obtains a target error value according to a current error value corresponding to current parameter values of at least two influencing parameters of the clock frequency to achieve calibration of the clock frequency, and reduces the clock frequency error under various environmental factors to an allowable error range, thereby ensuring the accuracy and precision of the RCO clock frequency, reducing the difficulty of chip design, and saving chip design costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] Figure 1 This is a flow chart of the clock frequency calibration method of Embodiment 1 of the present disclosure.
[0063] Figure 2 This is the first flow chart of the clock frequency calibration method of the second embodiment of the present disclosure.
[0064] Figure 3 This is the second flow chart of the clock frequency calibration method of Embodiment 2 of the present disclosure.
[0065] Figure 4 This is a flowchart of step S1022 in the clock frequency calibration method of embodiment 2 of the present disclosure.
[0066] Figure 5 This is a flowchart of step S1023 in the clock frequency calibration method of embodiment 2 of the present disclosure.
[0067] Figure 6 This is a specific example diagram of the clock frequency calibration method of embodiment 2 of the present disclosure.
[0068] Figure 7 This is a module diagram of a clock frequency calibration system according to Embodiment 3 of the present disclosure.
[0069] Figure 8 This is a module diagram of a clock frequency calibration system according to Embodiment 4 of the present disclosure.
[0070] Fig. 9 This is a schematic diagram of the structure of an electronic device according to Embodiment 5 of the present disclosure. DETAILED DESCRIPTION
[0071] The present disclosure is further described below by way of examples, but the present disclosure is not limited to the scope of the examples.
[0072] Prefixes such as "first" and "second" are used in the embodiments of the present disclosure only to distinguish different description objects, and have no limiting effect on the position, order, priority, quantity or content of the described objects. The use of prefixes such as ordinal numbers to distinguish description objects in the embodiments of the present disclosure does not constitute a limitation on the described objects. For the statement of the described objects, please refer to the description in the context of the claims or embodiments, and no unnecessary limitation should be constituted due to the use of such prefixes. In addition, in the description of the present embodiment, unless otherwise specified, the meaning of "plurality" is two or more.
[0073] In the embodiments of the present disclosure, the collection, storage, use, processing, transmission, provision and disclosure of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0074] Example 1
[0075] This embodiment provides a clock frequency calibration method. Figure 1 : is a flow chart of a clock frequency calibration method of this embodiment, and the calibration method includes:
[0076] S101, based on current parameter values of at least two influencing parameters of the clock frequency and a mapping relationship corresponding to each influencing parameter, obtaining a current error value of the clock frequency corresponding to the current parameter value of each influencing parameter;
[0077] Wherein, the mapping relationship corresponding to each influencing parameter is established based on several groups of historical parameter values of the influencing parameters corresponding to each other and the first historical error value of the clock frequency;
[0078] S102, obtaining a target error value of the clock frequency based on each current error value;
[0079] S103: Calibrate the standard frequency value of the clock frequency based on the target error value to obtain a target frequency value.
[0080] Specifically, when establishing the mapping relationship corresponding to each influencing parameter, the data corresponding to an influencing parameter is obtained by the control variable method, and the data is a plurality of sets of historical parameter values of the influencing parameter corresponding to each other and the first historical error value of the clock frequency. That is, when establishing the mapping relationship corresponding to one of the influencing parameters, the historical parameter values of other influencing parameters are kept unchanged, sufficient historical parameter values are measured within the parameter value range allowed by the influencing parameter corresponding to the device (such as a chip) to which the clock frequency belongs, and the first historical error value corresponding to each historical parameter value is obtained.
[0081] The mapping relationship corresponding to each influencing parameter can be programmed into the chip software. When the RCO clock needs to be used, the clock is first calibrated through the software. The mapping relationship can be represented by a curve or a function.
[0082] The clock frequency values under multiple sets of standard production line environments can be measured, and the average value of multiple sets of clock frequency values can be used as the standard frequency value of the clock frequency, and the standard frequency value can be written into the chip for storage. The standard production line environment includes an environment with a constant temperature of 20°C and a humidity of 20%. 20°C and 20% are just an example and can be set or adjusted according to actual conditions. The humidity value can be expressed in relative humidity (RH).
[0083] Each time the device is turned on, the current parameter value of each influencing parameter is measured, and the corresponding current error value is obtained according to the corresponding mapping relationship. Then, the target error value is obtained according to the current error value to calibrate the standard frequency value and obtain the target frequency value.
[0084] In this embodiment, a target error value is obtained according to a current error value corresponding to current parameter values of at least two parameters affecting the clock frequency to achieve calibration of the clock frequency, reduce the clock frequency error under various environmental factors to an allowable error range, ensure the accuracy and precision of the RCO clock frequency, reduce the difficulty of chip design, and save chip design costs.
[0085] The execution subject of the clock frequency calibration method provided in this embodiment may be a separate chip, a chip module or an electronic device, or a chip or a chip module integrated in an electronic device.
[0086] Example 2
[0087] This embodiment provides a clock frequency calibration method, which is a further improvement on Embodiment 1.
[0088] In one feasible solution, Figure 2 As shown, step S102 includes:
[0089] S1021. Taking the sum of each current error value as the target error value.
[0090] In this scheme, the sum of the current error values corresponding to the current parameter value of each influencing parameter of the clock frequency is taken as the target error value, and then the clock frequency is calibrated according to the target error value to obtain the target frequency value. The error influence caused by each influencing parameter of the clock frequency is taken into account, the accuracy of the target error value is guaranteed, and the accuracy and reliability of the target frequency value are improved.
[0091] In another feasible solution, Figure 3 As shown, step S102 includes:
[0092] S1022, obtaining a weight corresponding to each current error value;
[0093] S1023. Obtain a target error value based on each current error value and the corresponding weight.
[0094] In this scheme, a target error value is obtained based on each current error value and the corresponding weight, and then the clock frequency is calibrated based on the target error value to obtain the target frequency value. Each current error value corresponds to a current parameter value of an influencing parameter of the clock frequency. The weight corresponding to each current error value is considered, that is, the degree of error influence caused by each influencing parameter of the clock frequency is considered, thereby improving the accuracy and reliability of the target error value, and thus improving the accuracy and reliability of the target frequency value.
[0095] In one feasible solution, Figure 4 As shown, step S1022 includes:
[0096] S10221. Obtain the difference between the current parameter value and the standard parameter value of each influencing parameter;
[0097] S10222. Determine a weight corresponding to each current error value based on the gap value;
[0098] Among them, the weight is positively correlated with the gap value.
[0099] In this solution, the weight corresponding to each current error value is determined according to the difference between the current parameter value of each influencing parameter and the standard parameter value, thereby ensuring the accuracy and reliability of the weight setting.
[0100] In one implementable solution, the gap value includes a ratio or a difference.
[0101] Specifically, taking the ratio as the gap value as an example, after obtaining the first ratio between the current parameter value and the standard parameter value of each influencing parameter, the second ratio of each first ratio to the sum of all first ratios is used as the weight corresponding to each current error value.
[0102] In this solution, by taking the ratio or difference as the gap value and determining the weight corresponding to each current error value according to the ratio or difference, the accuracy and reliability of the weight setting is ensured.
[0103] In one feasible solution, Figure 5 As shown, step S1023 includes:
[0104] S10231. Obtain the product of each current error value and the corresponding weight;
[0105] S10232. Take the sum of each product as the target error value.
[0106] In this scheme, the sum of the products of each current error value and its corresponding weight is taken as the target error value, which ensures the accuracy and reliability of the target error value.
[0107] In an implementable solution, the first historical error value corresponding to each historical parameter value of each influencing parameter is an average value of a plurality of second historical error values corresponding to each historical parameter value of each influencing parameter;
[0108] The second historical error value is the difference between the historical frequency value of the clock frequency corresponding to the historical parameter value and the standard frequency value.
[0109] Specifically, taking temperature as an influencing parameter of the clock frequency as an example, the corresponding second historical error value is obtained, and then the first historical error value is obtained. Keeping the parameter values of other influencing parameters unchanged, measure the frequency values of 50 groups of RCO clocks in the temperature range of -30℃-100℃. Taking 2℃ as a measurement unit, measure the frequency values (i.e., historical frequency values) corresponding to 75 temperature values (i.e., historical parameter values) for each group of RCO clocks. The difference between each historical frequency value and the standard frequency value is taken as the second historical error value. For each group of 75 temperature values and 75 second historical error values of the RCO clock, with the temperature value as the horizontal coordinate and the second historical error value as the vertical coordinate, 75 coordinate points can be displayed in the rectangular coordinate system, and then the curve of temperature and the second historical error can be fitted. 50 groups of RCO clocks correspond to 50 curves, and a curve is further fitted based on the 50 curves, which is the mapping relationship of the influencing parameter of temperature. Each temperature value corresponds to 50 frequency values, that is, 50 second historical error values. A curve is further fitted based on the 50 curves, and the average value of the 50 second historical error values corresponding to each temperature value can be used as the first historical error value corresponding to each temperature value. The above values of 50 and 75, and the temperature ranges or temperature values of -30℃-100℃ and 2℃ are just examples and can be set or adjusted according to actual conditions.
[0110] Taking humidity as an influencing parameter of the clock frequency as an example, keeping the parameter values of other influencing parameters (including temperature) unchanged, measure the frequency values of 50 groups of RCO clocks in the relative humidity range of 0%-100%. Taking 5% as a measurement unit, measure the frequency values (i.e. historical frequency values) corresponding to 20 relative humidity values (i.e. historical parameter values) for each group of RCO clocks. The other processes are similar to the process of taking temperature as an influencing parameter of the clock frequency, and will not be repeated here. The values of 50, 0%, 100%, and 5% here are just an example and can be set or adjusted according to actual conditions.
[0111] In this scheme, by taking the average value of several second historical error values corresponding to each historical parameter value as the first historical error value corresponding to each historical parameter value, the accuracy and reliability of the first historical error value are guaranteed, and the accuracy and reliability of the mapping relationship corresponding to each influencing parameter of the clock frequency are further guaranteed.
[0112] In one feasible solution, step S103 includes:
[0113] S1031. Taking the sum of the target error value and the standard frequency value as the target frequency value.
[0114] In this solution, the sum of the target error value and the standard frequency value is used as the target frequency value, which realizes the calibration of the clock frequency and improves the accuracy and reliability of the target frequency value.
[0115] In an implementable solution, the parameters affecting the clock frequency include at least two of the following: ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and the operating voltage of the chip to which the clock frequency belongs.
[0116] The aging degree may be represented by an aging parameter, and the aging parameter is obtained according to the current working time of the chip to which the clock frequency belongs.
[0117] In this scheme, the corresponding current error values are obtained based on at least two of the influencing parameters of the clock frequency, such as ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and operating voltage, so as to calibrate the clock frequency to obtain the target clock frequency, thereby ensuring the accuracy and precision of the target clock frequency, reducing the difficulty of chip design, and saving chip design costs.
[0118] The working principle of the clock frequency calibration method of this embodiment is explained below with reference to specific examples:
[0119] ARM TrustZone technology (a system-wide security method) is used to divide the chip into a secure world and a non-secure world. A hardware clock monitoring circuit is used to monitor the clock divided by RCO100 (based on the 100M clock of RCO) to ensure the security and reliability of the TEE (Trusted Execution Environment) input clock. In this way, the secure world can reuse the clock of the non-secure world, that is, the clock is divided from the non-secure world, thereby reducing the cost and difficulty of secure clock design. Figure 6This is a specific example diagram of the clock frequency calibration method of this embodiment. When the device is produced, the output clock of RCO100 is calibrated using a precise 24M calibration clock (clk_24M) in a standard environment of constant temperature and humidity, and the standard frequency value of the calibration clock 100M is written into efuse (one-time programmable memory). Once this value is written, it cannot be modified, ensuring that the calibration value will not change. During use, the calibration value will calibrate the clock frequency under different temperatures and voltages, thereby ensuring the accuracy of the clock. Each time the device is powered on, the clock frequency calibration method is executed. The execution device of this calibration method is protected by a security module.
[0120] During the calibration process, first read the standard frequency value val from efuse, then use the temperature and humidity sensor to measure the ambient temperature temp and ambient humidity rh of the current chip, use the sensor to read the aging parameter aging of the current chip, bring the ambient temperature temp, ambient humidity rh and aging parameter aging into their respective corresponding mapping relationships, and obtain the corresponding current error values, namely the first error γ, the second error δ and the third error ζ; obtain the corresponding weights according to the ambient temperature temp, ambient humidity rh and aging parameter aging and the corresponding standard ambient temperature value, standard ambient humidity value and standard aging parameter value; calculate the product of γ, δ and ζ with the corresponding weights, and then calculate the sum of the three products as the target error value val_err; take the sum of the standard frequency value val and the target error value val_err as the target frequency value, so as to correct the RCO100 clock. Here, taking the sum of the current error values and the corresponding weight products as the target error value is just an example, and the sum of the current error values can also be taken as the target error value.
[0121] In this embodiment, a target error value is obtained based on current error values and weights corresponding to current parameter values of at least two influencing parameters of the clock frequency to calibrate the clock frequency, reduce the clock frequency error under various environmental factors to an allowable error range, ensure the accuracy and precision of the RCO clock frequency, reduce the difficulty of chip design, and save chip design costs.
[0122] Example 3
[0123] This embodiment provides a clock frequency calibration system. Figure 7 Schematic diagram of the module of the calibration system of this embodiment, the calibration system includes:
[0124] A current error value acquisition module 1 is used to obtain a current error value of the clock frequency corresponding to the current parameter value of each influencing parameter based on the current parameter values of at least two influencing parameters of the clock frequency and the mapping relationship corresponding to each influencing parameter;
[0125] Wherein, the mapping relationship corresponding to each influencing parameter is established based on several groups of historical parameter values of the influencing parameters corresponding to each other and the first historical error value of the clock frequency;
[0126] A target error value acquisition module 2 is used to obtain a target error value of the clock frequency based on each current error value;
[0127] The calibration module 3 is used to calibrate the standard frequency value of the clock frequency based on the target error value to obtain the target frequency value.
[0128] In this embodiment, a target error value is obtained according to a current error value corresponding to current parameter values of at least two parameters affecting the clock frequency to achieve calibration of the clock frequency, reduce the clock frequency error under various environmental factors to an allowable error range, ensure the accuracy and precision of the RCO clock frequency, reduce the difficulty of chip design, and save chip design costs.
[0129] The clock frequency calibration system described in the embodiment may specifically be a separate chip, chip module or electronic device, or a chip or chip module integrated into an electronic device. The various modules / units included in the clock frequency calibration system may be software modules / units, hardware modules / units, or partly software modules / units and partly hardware modules / units. For example, for various devices and products applied to or integrated in a chip, the various modules / units included therein may all be implemented in the form of hardware such as circuits, or at least some of the modules / units may be implemented in the form of software programs, which run on a processor integrated inside the chip, and the remaining modules / units may be implemented in the form of hardware such as circuits; for various devices and products applied to or integrated in a chip module, the various modules / units included therein may all be implemented in the form of hardware such as circuits, and different modules / units may be located in the same component (such as a chip, circuit module, etc.) or different components of the chip module, or at least some of the modules / units may be implemented in the form of hardware such as circuits. The element can be implemented in the form of a software program, which runs on a processor integrated inside the chip module, and the remaining modules / units can be implemented in the form of hardware such as circuits; for various devices and products applied to or integrated in electronic devices, the various modules / units contained therein can be implemented in the form of hardware such as circuits, and different modules / units can be located in the same component (for example, chip, circuit module, etc.) or in different components in the terminal, or, at least some modules / units can be implemented in the form of a software program, which runs on a processor integrated inside the electronic device, and the remaining modules / units can be implemented in the form of hardware such as circuits.
[0130] Example 4
[0131] This embodiment provides a clock frequency calibration system, which is a further improvement on the third embodiment. Figure 8 FIG. 4 is a schematic diagram of modules of a clock frequency calibration system according to the present embodiment.
[0132] In an implementable solution, the target error value acquisition module 2 includes:
[0133] The first error value obtaining unit 21 is used to take the sum of each current error value as a target error value.
[0134] In an implementable solution, the target error value acquisition module 2 includes:
[0135] A weight acquisition unit 22, used to acquire a weight corresponding to each current error value;
[0136] The second error value obtaining unit 23 is used to obtain a target error value based on each current error value and a corresponding weight.
[0137] In another practicable solution, the weight acquisition unit 22 includes:
[0138] The gap value acquisition subunit 221 is used to acquire the gap value between the current parameter value and the standard parameter value of each influencing parameter;
[0139] The weight acquisition subunit 222 is used to determine the weight corresponding to each current error value based on the gap value;
[0140] Among them, the weight is positively correlated with the gap value.
[0141] In one implementable solution, the gap value includes a ratio or a difference.
[0142] In an implementable solution, the second error value obtaining unit 23 includes:
[0143] A product acquisition subunit 231 is used to obtain the product of each current error value and the corresponding weight;
[0144] The error value acquisition subunit 232 is used to take the sum of each product as a target error value.
[0145] In an implementable solution, the first historical error value corresponding to each historical parameter value of each influencing parameter is an average value of a plurality of second historical error values corresponding to each historical parameter value of each influencing parameter;
[0146] The second historical error value is the difference between the historical frequency value of the clock frequency corresponding to the historical parameter value and the standard frequency value.
[0147] In an implementable solution, the calibration module 3 is further configured to use the sum of the target error value and the standard frequency value as the target frequency value.
[0148] In an implementable solution, the parameters affecting the clock frequency include at least two of the following: ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and the operating voltage of the chip to which the clock frequency belongs.
[0149] In this embodiment, a target error value is obtained based on current error values and weights corresponding to current parameter values of at least two influencing parameters of the clock frequency to calibrate the clock frequency, reduce the clock frequency error under various environmental factors to an allowable error range, ensure the accuracy and precision of the RCO clock frequency, reduce the difficulty of chip design, and save chip design costs.
[0150] As for the system embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The system embodiment described above is only illustrative, wherein the units described as separate components may or may not be physically separated, and the components as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the disclosed solution.
[0151] Example 5
[0152] like Fig. 9 As shown, it is a structural schematic diagram of an electronic device provided in Embodiment 5 of the present disclosure, the electronic device includes a memory, a processor and a computer program stored in the memory and used to run on the processor, and when the processor executes the computer program, the clock frequency calibration method of the above embodiment is implemented. Fig. 9 The electronic device 90 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0153] The electronic device 90 may be in the form of a general-purpose computing device, for example, it may be a server device. The components of the electronic device 90 may include, but are not limited to: at least one processor 91, at least one memory 92, and a bus 93 connecting different system components (including the memory 92 and the processor 91).
[0154] The bus 93 includes a data bus, an address bus, and a control bus.
[0155] The memory 92 may include a volatile memory, such as a random access memory (RAM) 921 and / or a cache memory 922 , and may further include a read-only memory (ROM) 923 .
[0156] The memory 92 may also include a program tool 925 (or utility) having a set (at least one) of program modules 924, such program modules 924 including but not limited to: an operating system, one or more application programs, other program modules and program data, each of which or some combination may include an implementation of a network environment.
[0157] The processor 91 executes various functional applications and data processing by running the computer programs stored in the memory 92, such as the clock frequency calibration method provided in the above embodiment.
[0158] The electronic device 90 may also communicate with one or more external devices 94 (e.g., keyboards, pointing devices, etc.). Such communication may be performed via an input / output (I / O) interface 95. Furthermore, the electronic device 90 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 96. As shown, the network adapter 96 communicates with other modules of the electronic device 90 via a bus 93. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 90, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID (disk array) systems, tape drives, and data backup storage systems, etc.
[0159] It should be noted that although several units / modules or sub-units / modules of the electronic device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more units / modules described above can be embodied in one unit / module. Conversely, the features and functions of one unit / module described above can be further divided into multiple units / modules to be embodied.
[0160] Example 6
[0161] An embodiment of the present disclosure further provides a computer-readable storage medium having a computer program stored thereon, and when the program is executed by a processor, the clock frequency calibration method provided by any of the above embodiments is implemented.
[0162] The readable storage medium may include but is not limited to: a portable disk, a hard disk, a random access memory, a read-only memory, an erasable programmable read-only memory, an optical storage device, a magnetic storage device or any suitable combination of the above.
[0163] Example 7
[0164] An embodiment of the present disclosure further provides a computer program product, including a computer program, which implements any of the above-mentioned clock frequency calibration methods when executed by a processor.
[0165] Among them, the program code for executing the computer program product of the present disclosure can be written in any combination of one or more programming languages, and the program code can be executed completely on the user device, partially on the user device, as an independent software package, partially on the user device and partially on a remote device, or completely on the remote device.
[0166] Although the specific embodiments of the present disclosure are described above, those skilled in the art should understand that this is only an example, and the protection scope of the present disclosure is defined by the appended claims. Those skilled in the art may make various changes or modifications to these embodiments without departing from the principles and essence of the present disclosure, but these changes and modifications all fall within the protection scope of the present disclosure.
Claims
1. A method for calibrating a clock frequency, characterized in that: The calibration method comprises: Based on current parameter values of at least two influencing parameters of the clock frequency and a mapping relationship corresponding to each of the influencing parameters, obtaining a current error value of the clock frequency corresponding to the current parameter value of each of the influencing parameters; Wherein, the mapping relationship corresponding to each of the influencing parameters is established based on a plurality of groups of mutually corresponding historical parameter values of the influencing parameters and a first historical error value of the clock frequency; Based on each of the current error values, obtaining a target error value of the clock frequency; The standard frequency value of the clock frequency is calibrated based on the target error value to obtain a target frequency value.
2. The clock frequency calibration method according to claim 1, characterized in that: The step of obtaining the target error value of the clock frequency based on each of the current error values comprises: The sum of each of the current error values is taken as the target error value.
3. The clock frequency calibration method according to claim 1, characterized in that: The step of obtaining the target error value of the clock frequency based on each of the current error values comprises: Obtaining a weight corresponding to each of the current error values; Based on each of the current error values and the corresponding weight, the target error value is obtained.
4. The clock frequency calibration method according to claim 3, characterized in that: The step of obtaining the weight corresponding to each current error value comprises: Obtaining a difference value between the current parameter value and the standard parameter value of each of the influencing parameters; Based on the gap value, determine the weight corresponding to each of the current error values; The weight is positively correlated with the gap value.
5. The clock frequency calibration method according to claim 4, characterized in that: The gap value includes a ratio or a difference.
6. The clock frequency calibration method according to claim 3, characterized in that: The step of obtaining the target error value based on each of the current error values and the corresponding weight comprises: Obtaining the product of each current error value and the corresponding weight; The sum of each of the products is taken as the target error value.
7. The clock frequency calibration method according to any one of claims 1 to 6, characterized in that: The first historical error value corresponding to each of the historical parameter values of each of the influencing parameters is an average value of a plurality of second historical error values corresponding to each of the historical parameter values of each of the influencing parameters; The second historical error value is a difference between a historical frequency value of the clock frequency corresponding to the historical parameter value and the standard frequency value; and / or, The step of calibrating the standard frequency value of the clock frequency based on the target error value to obtain the target frequency value comprises: Taking the sum of the target error value and the standard frequency value as the target frequency value; and / or, The influencing parameters of the clock frequency include at least two of ambient temperature, ambient electromagnetic radiation energy, ambient mechanical vibration amplitude, ambient humidity, aging degree, and an operating voltage of a chip to which the clock frequency belongs.
8. A clock frequency calibration system, characterized in that: The calibration system comprises: A current error value acquisition module, configured to obtain a current error value of the clock frequency corresponding to the current parameter value of each influencing parameter based on current parameter values of at least two influencing parameters of the clock frequency and a mapping relationship corresponding to each of the influencing parameters; The mapping relationship corresponding to each of the influencing parameters is established based on a plurality of groups of corresponding historical parameter values of the influencing parameters and a first historical error value of the clock frequency; A target error value acquisition module, used to obtain a target error value of the clock frequency based on each of the current error values; The calibration module is used to calibrate the standard frequency value of the clock frequency based on the target error value to obtain a target frequency value.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and used to run on the processor, characterized in that: When the processor executes the computer program, the clock frequency calibration method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the clock frequency calibration method according to any one of claims 1 to 7 is implemented.
11. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the clock frequency calibration method according to any one of claims 1 to 7 is implemented.
12. A chip, characterized in that: A computer program is stored on the chip, and when the computer program is executed by the chip, the clock frequency calibration method according to any one of claims 1 to 7 is implemented.
13. A chip module, applied to electronic equipment, characterized in that: It comprises a transceiver component and a chip, and the chip is used to implement the clock frequency calibration method as described in any one of claims 1-7.
Citation Information
Cited By
Clock adjustment method, clock and electronic equipment
CN120630630A
