Implementation method for automatic adjustment of closed-loop control loop compensation speed
By adopting closed-loop control loop compensation speed automatic adjustment method in digital power supply, the loop compensation speed is dynamically adjusted, which solves the problem of difficult response of power systems in the existing technology in extreme environments, and achieves rapid voltage recovery and improved system stability.
Patent Information
- Application Number
- CN202411001323.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-25
- Publication Date
- 2024-11-22
- Estimated Expiration
- 2044-07-25
AI Technical Summary
Existing power systems are difficult to respond quickly to dynamic load changes in extreme usage environments, resulting in overshoot or drop of output voltages, and lack flexible loop compensation speed adjustment methods to maintain stability.
By using the closed-loop control loop compensation speed automatic adjustment method in the digital power supply, the MCU performs real-time sampling and operation, updates the timer period value according to the sample value and target value, realizes frequency and pulse width modulation of the PWM drive signal, and dynamically adjusts the loop Road compensation speed.
It realizes rapid recovery of normal operating voltage range when dynamic load changes, improves system stability and loop compensation flexibility, and reduces dynamic load response recovery time.
Smart Images

Figure CN119010595A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of control technology, and in particular to a method for realizing automatic regulation of closed-loop control loop compensation speed. Background Art
[0002] With the rapid development of society, power electronics technology has been widely used in various fields. In some specific applications, such as large server rooms and laser cutting technology, the performance requirements of digital power supply are very high. In addition to high efficiency, stable voltage and current, it also needs to have a high dynamic response speed to ensure the stability of the power supply to the overall system under different working environments.
[0003] The compensation speed of the conventional voltage / current loop is fixed. The implementation method is: by configuring the timer, and letting the timer generate a periodic value update interrupt, and finally running the relevant functions of the voltage / current loop in the interrupt service function. That is, every time the timer is updated, the voltage / current loop will calculate the error value, perform loop calculation and load, and output the required PWM drive. Because the voltage / current loop is based on the timer, the compensation speed of the loop also depends on the period value of the timer. For example, when the timer is configured to 50KHz, that is, 20us, the compensation speed of the loop is also fixed to 50KHz.
[0004] When the digital power supply is in a relatively extreme use environment, such as switching between output no-load and full-load, the output voltage will overshoot or drop out of the specification range for a period of time, and then return to the normal range. This is because when the load changes instantly, the original loop compensation result is not enough to maintain the stability of the current output voltage. The latest loop compensation result of the current change needs to be detected to maintain the voltage stability. The time required during this period is the dynamic load response recovery time. In order to reduce the dynamic load response recovery time and increase the flexibility of loop compensation, it is necessary to adopt a control method that can automatically adjust the loop compensation speed.
[0005] Therefore, it is necessary to provide a method for automatically adjusting the closed-loop control loop compensation speed to achieve automatic adjustment of the loop compensation speed, that is, the compensation speed changes with the change of the real-time operation result of the loop to ensure power supply stability. Summary of the invention
[0006] The invention discloses a method for realizing automatic adjustment of closed-loop control loop compensation speed, belongs to the field of control technology, is suitable for closed-loop control of digital power supply, and can effectively solve the technical problems involved in the background technology.
[0007] To achieve the above object, the technical solution of the present invention is:
[0008] A method for realizing automatic adjustment of closed-loop control loop compensation speed comprises the following steps:
[0009] S1, the sampling module samples information from the power control circuit, and the sampled value is transmitted to the controller MCU;
[0010] S2, MCU performs loop operation according to the sampled value and the preset target value. The result of the loop operation is the frequency f. MCU performs PWM control on the switch tube of the power control circuit according to the value of f.
[0011] S3, MCU contains a timer Timer, the period value of the Timer is T, and the Timer interrupt is triggered when the Timer counter accumulates to the period value. The MCU CPU performs a loop operation when responding to the interrupt;
[0012] S4, T = 1 / f, MCU continuously updates the period value T of the Timer according to the value of the real-time loop calculation result f.
[0013] In the DC-DC power control module of the digital power supply, in order to make the output voltage / current reach the target value and maintain stability, the MCU needs to output PWM drive signals with different pulse widths and frequencies to control the on and off time of the power MOSFET, and the pulse width and frequency of the PWM square wave output by the MCU are determined by the voltage / current loop operation results. When the digital power supply is working under dynamic load changes or other extreme environments, the output voltage may overshoot or fall outside the specification range for a period of time, which poses certain risks to the power supply and even the system. Compared with the conventional constant closed-loop control compensation speed, the automatic adjustment of the closed-loop control compensation speed of the present invention has the advantages of being faster and more flexible. When the above situation occurs, the power supply can quickly return to the normal operating voltage range, thereby ensuring the stability of the entire system.
[0014] As a preferred improvement of the present invention: the loop operation includes but is not limited to the pi or 2p2z algorithm.
[0015] As a preferred improvement of the present invention: in the step S3, when the period value T triggers the Timer interrupt, the MCU loads the result of the last loop operation and executes the loop operation at the same time.
[0016] As a preferred improvement of the present invention: the sampling module includes a voltage sampling circuit and a current sampling circuit.
[0017] As a preferred improvement of the present invention: the loop operation result f is set at 50-200KHz.
[0018] As a preferred improvement of the present invention: the power control module is a DC-DC circuit, the DC-DC circuit includes a port Vdc+ and a port Vdc-, the port Vdc+ is connected to the drain of the MOS tube Q1, the source of the MOS tube Q1 is connected to the drain of the MOS tube Q2 and one end of the capacitor Cr, the other end of the capacitor Cr is connected to one end of the inductor Lr, the other end of the inductor Lr is connected to one end of the inductor Lm and the pin 1 of the transformer T1, the port Vdc- is connected to the source of the MOS tube Q2, the other end of the inductor Lm and the pin 2 of the transformer T1; the pin 6 of the transformer is connected to the positive end of the diode D1, the negative end of the diode D1 is connected to the negative end of the diode D2, one end of the capacitor Co and one end of the resistor Ro, the pin 5 of the transformer T1 is connected to the pin 4 of the transformer T1, the other end of the capacitor Co and the other end of the resistor Ro, and the pin 3 of the transformer T1 is connected to the positive end of the diode D2.
[0019] As a preferred improvement of the present invention: in the step S1, the sampling module samples the voltage and current across the resistor Ro, and the sampled values are transmitted to the controller MCU.
[0020] The beneficial effects of the present invention are as follows:
[0021] The real-time sampling value is compared with the target value to obtain the error value and feed it back to the loop operation. One path of the loop operation result is used for PWM output, and the other path is used to adjust the speed of loop compensation. Taking the modulation method of fixed pulse width modulation frequency as an example, the larger the frequency value output by the loop operation result, the smaller the period, and the faster the compensation speed; the smaller the frequency value output by the loop operation result, the larger the period, and the slower the compensation speed. In the event of an accident, the power supply can quickly return to the normal operating voltage range, thereby ensuring the stability of the entire system. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work, among which:
[0023] Figure 1 It is the loop operation flow chart;
[0024] Figure 2 This is a schematic diagram of loop compensation speed fixation;
[0025] Figure 3 It is a schematic diagram of loop compensation speed change;
[0026] Figure 4is a schematic diagram of a power control circuit;
[0027] Figure 5 This is the LLC gain curve. DETAILED DESCRIPTION
[0028] The technical solutions in the embodiments of the present invention will be described clearly and completely below in combination with the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0029] It should be noted that all directional indications in the embodiments of the present invention (such as up, down, left, right, front, back, etc.) are only used to explain the relative position relationship, movement status, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly.
[0030] In addition, in the present invention, descriptions such as "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0031] In the present invention, unless otherwise clearly specified and limited, the terms "connection", "fixation", etc. should be understood in a broad sense. For example, "fixation" can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0032] In addition, the technical solutions between the various embodiments of the present invention can be combined with each other, but it must be based on the fact that ordinary technicians in the field can implement it. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by the present invention.
[0033] See also Figure 4As shown, the figure is a schematic diagram of a DC / DC circuit, the power control module is a DC-DC circuit, and the DC-DC circuit includes a port Vdc+ and a port Vdc-, the port Vdc+ is connected to the drain of the MOS tube Q1, the source of the MOS tube Q1 is connected to the drain of the MOS tube Q2 and one end of the capacitor Cr, the other end of the capacitor Cr is connected to one end of the inductor Lr, the other end of the inductor Lr is connected to one end of the inductor Lm and the pin 1 of the transformer T1, the port Vdc- is connected to the source of the MOS tube Q2, the other end of the inductor Lm and the pin 2 of the transformer T1; the pin 6 of the transformer is connected to the positive end of the diode D1, the negative end of the diode D1 is connected to the negative end of the diode D2, one end of the capacitor Co and one end of the resistor Ro, the pin 5 of the transformer T1 is connected to the pin 4 of the transformer T1, the other end of the capacitor Co and the other end of the resistor Ro, and the pin 3 of the transformer T1 is connected to the positive end of the diode D2. Pins 1 and 2 of the transformer T1 share one coil, pins 3 and 4 share one coil, and pins 5 and 6 share one coil. The MCU samples the output voltage and output current of the circuit and controls the operation of the MOS tube.
[0034] See also Figure 2 As shown in the figure, the compensation speed of the traditional controller is determined by the period value of the Timer, which is a fixed value, that is, the compensation speed remains unchanged. In case of emergencies, the power supply is prone to fall out of the normal working state and stay for a long time. Figure 2 As shown in the figure, the fixed loop compensation speed is based on a 20us timer. When the period value is updated and an interrupt is generated, the last loop output result is loaded and the current loop calculation is started. The loop calculation is completed within the next 20us. PWM is Pulse Width Modulation, a pulse width modulation technology. MCU is Micro Control Unit, a micro control unit. Timer refers to the timer, PI and 2P2Z are power loop compensation algorithms, LLC is a series-parallel resonant converter, and MosFet is a field effect transistor.
[0035] The present invention provides a method for realizing automatic adjustment of closed-loop control loop compensation speed, comprising the following steps:
[0036] S1, the sampling module samples information from the power control circuit, and the sampled value is transmitted to the controller MCU, the sampling module includes a voltage sampling circuit and a current sampling circuit;
[0037] S2. The MCU performs a loop operation according to the sampled value and the preset target value. The result of the loop operation is the frequency f. The MCU performs PWM control on the switch tube of the power control circuit according to the value of f. The loop operation includes but is not limited to the pi or 2p2z algorithm.
[0038] S3, MCU includes a timer Timer, the period value of the Timer is T, when the counter reaches the period value T, the MCU performs a loop operation and loads the result of the last loop operation;
[0039] S4, T = 1 / f, MCU continuously updates the period value T of the Timer according to the value of the real-time loop calculation result f.
[0040] See also Figure 3 As shown, the loop compensation speed of the present invention is variable, and the loop compensation speed is determined by the loop operation result. The larger the frequency value output by the loop operation result, the smaller the period, and the faster the compensation speed; the smaller the frequency value output by the loop operation result, the larger the period, and the slower the compensation speed. Figure 3 As shown, the loop compensation speed is changed based on the period value of the HRTIM Master Timer, and the period value of the HRTIM Master Timer comes from the real-time loop output result. When the period value update generates an interrupt, the last loop output result is loaded and the current loop calculation is started. The loop calculation needs to be completed within the HRTIM Master Timer period value. The solution of the present invention realizes automatic adjustment of the loop compensation speed, that is, the compensation speed changes with the change of the real-time loop calculation result.
[0041] Embodiment 1
[0042] 1. Implement the PWM drive bottom configuration according to the DC-DC topology to be applied. Taking ST's G4 series chip as an example, the HRTIM peripherals used to configure the PWM drive are composed of Master Timer and Slave Timer A to F. Slave Timer A to F are used as the output of the PWM drive signal, and control the opening and closing of the power MOS tube by loading Compare 1 to 4, while the Master Timer is used as a timer function to run the related functions of the voltage / current loop.
[0043] 2. Open the period value update interrupt of Master Timer in the configuration, then pre-write the related functions of voltage / current loop, and run them in the interrupt service function of Maser Timer. When the count value of Master Timer overflows and generates a period value update interrupt, the data operation of voltage / current loop (existing method) will be executed in the interrupt service function.
[0044] 3. The relevant loop function compares the real-time voltage / current sampling data with the preset target value to obtain the error value, and then feeds the error value back to the pi or 2p2z loop for a series of calculations to obtain the loop operation result.
[0045] 4. In addition to acting on the PWM output pin of the microcontroller to output the desired pulse width or frequency to control the power MOSFET, the loop operation result also assigns the period value of the Master Timer in the interrupt service function. The period value of the MasterTimer will change with the change of the real-time operation result of the loop, that is, the number of times the voltage / current loop data operation is executed each time the interrupt service function is entered in the same time will also change, thereby realizing the automatic adjustment function of the loop compensation speed, such as Figure 1 shown.
[0046] 5. Limit the minimum / maximum frequency of PWM output in the loop function, such as 55KHz and 200KHz (for example: if it is less than 55KHz, the output will be 55KHz). Refer to the LLC gain curve (such as Figure 5 ) It can be seen that when the resonant cavity works in the inductive region and is greater than the second resonant frequency, the smaller the frequency, the higher the gain value. When the power supply works in an environment with a large output load, the frequency value calculated by the loop is lower and the period value is larger. At this time, the loop compensation speed is the normal compensation speed. When the power supply works in an environment with a small output load, the frequency value calculated by the loop is higher and the period value is smaller. At this time, the loop compensation speed will be automatically increased.
[0047] When the power supply is operating in an environment with a wide range of dynamic load changes, the advantages of automatic loop compensation speed adjustment are as follows:
[0048] When the load is light, the calculated frequency value is higher. The higher loop compensation speed allows the loop to react quickly and output the appropriate PWM drive in time when the power supply is instantly switched to heavy load, allowing the power supply to return to the normal operating voltage faster, thereby reducing the dynamic load response recovery time.
[0049] When the load is heavy, the calculated frequency value is lower. When the power supply is switched to light load, the frequency value calculated by the loop is increasing, and the loop compensation speed is also increasing synchronously. The loop can also respond quickly and output the appropriate PWM drive in time, so that the power supply returns to the normal operating voltage faster, thereby reducing the dynamic load response recovery time.
[0050] Although the embodiments of the present invention have been disclosed as above, they are not limited to the applications listed in the specification and the embodiments. They can be fully applied to various fields suitable for the present invention. For those familiar with the art, additional modifications can be easily implemented. Therefore, without departing from the general concept defined by the claims and the scope of equivalents, the present invention is not limited to the specific details and the illustrations shown and described herein.
Claims
1. A method for realizing automatic adjustment of closed-loop control loop compensation speed, characterized in that: The following steps are involved: S1, the sampling module samples information from the power control circuit, and the sampled value is transmitted to the controller MCU; S2, MCU performs loop operation according to the sampled value and the preset target value. The result of the loop operation is the frequency f. MCU performs PWM control on the switch tube of the power control circuit according to the value of f. S3, MCU contains a timer Timer, the period value of the Timer is T, and the Timer interrupt is triggered when the Timer counter accumulates to the period value. The MCU CPU performs a loop operation when responding to the interrupt; S4, T = 1 / f, MCU continuously updates the period value T of the Timer according to the value of the real-time loop calculation result f.
2. The method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 1, characterized in that: The loop operation includes but is not limited to the pi or 2p2z algorithm.
3. The method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 1, characterized in that: In step S3, when the period value T triggers the Timer interrupt, the MCU loads the result of the last loop operation and executes the loop operation at the same time.
4. The method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 1, characterized in that: The sampling module includes a voltage sampling circuit and a current sampling circuit.
5. The method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 1, characterized in that: The loop operation result f is set at 50-200KHz.
6. The method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 1, characterized in that: The power control module is a DC-DC circuit, which includes a port Vdc+ and a port Vdc-, wherein the port Vdc+ is connected to the drain of the MOS tube Q1, the source of the MOS tube Q1 is connected to the drain of the MOS tube Q2 and one end of the capacitor Cr, the other end of the capacitor Cr is connected to one end of the inductor Lr, the other end of the inductor Lr is connected to one end of the inductor Lm and the pin 1 of the transformer T1, and the port Vdc- is connected to the source of the MOS tube Q2, the other end of the inductor Lm and the pin 2 of the transformer T1; Pin 6 of the transformer is connected to the positive end of the diode D1, the negative end of the diode D1 is connected to the negative end of the diode D2, one end of the capacitor Co and one end of the resistor Ro, the pin 5 of the transformer T1 is connected to the pin 4 of the transformer T1, the other end of the capacitor Co and the other end of the resistor Ro, and the pin 3 of the transformer T1 is connected to the positive end of the diode D2.
7. A method for realizing automatic adjustment of closed-loop control loop compensation speed according to claim 6, characterized in that: In the step S1, the sampling module samples the voltage and current across the resistor Ro, and the sampled values are transmitted to the controller MCU.
Citation Information
Patent Citations
Enhancement of power conversion efficiency using dynamic load detecting and tracking
CN101785173A
Temperature compensation voltage-controlled oscillator and compensation method
CN108649902A
Loop compensation circuit and compensation method for voltage-controlled isolation type DC / DC converter
CN109327146A
Feedback loop compensation switching circuit and driving power supply
CN109496009A
EMC filtering control circuit and method
CN111478579A
Cited By
Method for dynamically improving circuit driving wave transmission
CN119727409A
A method for dynamically improving the driving of a wave by a circuit
CN119727409B
