A digital power supply output short circuit fault processing device and processing method thereof
By detecting and counting short-circuit faults, combined with timing functions and digital compensation circuits, the difficult problem of handling output short-circuit faults in digital power supplies is solved, achieving reliable operation of the system and rapid recovery from short-circuit faults.
Patent Information
- Application Number
- CN202111308356.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-05
- Publication Date
- 2024-10-01
- Estimated Expiration
- 2041-11-05
AI Technical Summary
In digital power supplies, it is difficult to deal with output short-circuit faults, especially in complex power topologies. Existing technologies lead to unnecessary system shutdowns, and increasing short-circuit current will increase the current stress of power devices, affecting reliable operation.
By defining the output short-circuit signal, the hardware comparator and MCU are used to detect short-circuit faults. The counter records the number of short-circuit occurrences, and combines the timing function to determine whether there is a real short-circuit, avoiding false triggering of shutdown, and quickly restoring the output voltage through the analog-to-digital converter and digital compensation circuit.
It effectively avoids shutdown due to mis-triggered short-circuit faults, ensures reliable operation of the system, and achieves reliable shutdown in the event of a real short-circuit, reducing the current stress of the power module.
Smart Images

Figure CN113922651B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of switching power supplies, and in particular relates to a digital power supply output short circuit fault processing device and a processing method thereof. Background Art
[0002] In the field of switching digital power supplies, output short circuit fault is an important fault. At present, most switching power supplies use cycle-by-cycle protection technology to handle output short circuit faults. However, in digital power supplies, cycle-by-cycle technology is difficult to implement, especially when the power topology is complex. Therefore, the current digital power supply handles output short circuit faults in a relatively simple way, that is, by using MCU (controller unit, such as single-chip microcomputer or DSP) to detect output short circuit signals. When a short circuit signal is detected, hiccup protection is performed (automatic restart after a period of shutdown).
[0003] With the complexity and changeability of digital power application conditions, especially when there is a surge step in the input voltage or a large capacitance in the output load, the sudden change in input voltage or the switching of loads can easily trigger an output short-circuit fault, causing unnecessary shutdown of the system and affecting the reliable operation of the system; and if the short-circuit current value is simply increased, the current stress of the power device will increase, causing unreliable operation of the power module. Summary of the invention
[0004] The purpose of the present invention is to overcome the deficiencies of the prior art and provide a digital power supply output short circuit fault processing device.
[0005] The objective of the present invention is achieved through the following technical solutions:
[0006] A method for processing a digital power supply output short circuit fault comprises the following steps:
[0007] S1: define an output short-circuit signal, the output short-circuit signal is sent through a hardware comparator circuit, the MCU receives the short-circuit signal through a short-circuit signal pin, and the MCU uses an internal register or marks the short-circuit signal state as HardWare_Short_Flag;
[0008] S2: Determine whether HardWare_Short_Flag is set. If the flag is set, it means that a short circuit fault has been triggered.
[0009] S3: Determine whether the timing flag Timer_Short_Flag is set. If Timer_Short_Flag=0, start the timing function.
[0010] S4: Determine whether the short-circuit fault flag SoftWare_Short_Flag is set. When the short-circuit fault flag is 0, the short-circuit fault is detected for the first time. The SoftWare_Short_Flag short-circuit fault flag is in the set state, and the MCU short-circuit signal pin level state does not respond. When the SoftWare_Short_Flag short-circuit fault flag is 1, the short-circuit fault is detected and processed.
[0011] S5: Perform recovery operation on the short-circuit fault, clear the short-circuit fault flag SoftWare_Short_Flag, clear HardWare_Short_Flag, and enable the MCU short-circuit signal pin function, re-enable the PWM drive signal output, counter Module_Short_Count++, the counter records how many short-circuit faults have occurred within a period of time.
[0012] Furthermore, the step S1 also includes the following steps: the short-circuit signal acts on the PWM unit, and when a short-circuit fault occurs, the PWM immediately enters an invalid state.
[0013] Furthermore, the step S5 also includes the following steps: determining whether the timer is greater than the timing period TIMER_PREIOD, determining whether the counter Module_Short_Count is greater than MODULE_SHORT, MODULE_SHORT represents the maximum value of a short circuit that may occur in a timing period, and identifying that when the counter Module_Short_Count is greater than MODULE_SHORT, multiple output short circuit faults have occurred within a timing period, the output short circuit is established, and the shutdown flag Module_Stop_Flag is set; when the counter Module_Short_Count is less than MODULE_SHORT, the shutdown flag Module_Stop_Flag is cleared; it should be noted that the timing period TIMER_PREIOD is specifically confirmed according to the actual use conditions. Generally, 1ms or 2ms is reasonable.
[0014] Further, it is determined whether the shutdown flag Module_Stop_Flag is set. When it is determined that the shutdown flag Module_Stop_Flag is set, the shutdown operation is performed.
[0015] A digital power supply output short circuit fault processing device, comprising an analog-to-digital converter, for receiving the output voltage of the digital power supply, and comparing it with n reference values, and converting the comparison result into a digital error signal representing the error between the current output voltage of the digital power supply and the expected output voltage, n≥3;
[0016] A digital compensation circuit receives the digital error signal to generate a digital duty cycle signal accordingly; the dynamic component of the digital duty cycle signal represents the error information between the current output voltage of the digital power supply and the expected output voltage;
[0017] The dynamic component of the digital duty cycle signal is transmitted to the analog-to-digital converter to correspondingly adjust the values of all or part of the reference value to approach the desired output voltage;
[0018] A DPWM module, the DPWM module includes an MCU and a PWM, and generates a PWM control signal to control the switching action of the power switch in the digital power supply according to the received digital duty cycle signal, so as to ensure that the output voltage of the digital power supply is consistent with the expected output voltage, and when the output voltage of the digital power supply is inconsistent with the expected output voltage, ensure that the output voltage of the digital power supply is quickly restored to the expected output voltage.
[0019] Furthermore, the analog-to-digital converter includes a plurality of comparators, a first input terminal of the comparator receives the output voltage of the digital power supply, and a second input terminal of the comparator receives the reference value.
[0020] Preferably, the PWM control signal output by the digital power supply control circuit is used to control the switching action of the power switch in the digital power supply.
[0021] The beneficial effects of the present invention are as follows: by analyzing and comparing short-circuit data, the present invention can effectively avoid shutdowns caused by falsely triggered short-circuit faults, thereby ensuring reliable operation of the system; and can ensure that when the output is truly short-circuited, reliable shutdown is achieved, thereby ensuring reliable operation of the power module. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] Figure 1 It is a fault judgment flow chart of the present invention;
[0023] Figure 2 This is a fault handling flow chart of the present invention;
[0024] Figure 3 This is a digital power supply circuit diagram of the present invention. DETAILED DESCRIPTION
[0025] The technical solution of the present invention will be clearly and completely described below in conjunction with the embodiments. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0026] See also Figure 1-3The present invention provides a technical solution: a method for processing a digital power supply output short circuit fault, comprising the following steps:
[0027] S1: Define the output short-circuit signal. The output short-circuit signal is sent through the hardware comparator circuit. The MCU receives the short-circuit signal through the short-circuit signal pin. The MCU uses the internal register or marks the short-circuit signal status as HardWare_Short_Flag.
[0028] S2: Determine whether HardWare_Short_Flag is set. If the flag is set, it means that a short circuit fault has been triggered.
[0029] S3: Determine whether the timing flag Timer_Short_Flag is set. If Timer_Short_Flag=0, start the timing function.
[0030] S4: Determine whether the short-circuit fault flag SoftWare_Short_Flag is set. When the short-circuit fault flag is 0, the short-circuit fault is detected for the first time. The SoftWare_Short_Flag short-circuit fault flag is set, and the MCU short-circuit signal pin level state does not respond; when the SoftWare_Short_Flag short-circuit fault flag is 1, the short-circuit fault is detected and processed;
[0031] S5: Perform recovery operation on the short-circuit fault, clear the short-circuit fault flag SoftWare_Short_Flag, clear HardWare_Short_Flag, and turn on the MCU short-circuit signal pin function at the same time, re-enable the PWM drive signal output, and set the counter Module_Short_Count++. The counter records how many short-circuit faults have occurred within a period of time.
[0032] Furthermore, step S1 also includes the following steps: a short-circuit signal acts on the PWM unit, and when a short-circuit fault occurs, the PWM immediately enters an invalid state.
[0033] Further, step S5 also includes the following steps: determining whether the timer is greater than the timing period TIMER_PREIOD, determining whether the counter Module_Short_Count is greater than MODULE_SHORT, MODULE_SHORT represents the maximum value of a short circuit that may occur in a timing period, and identifying that when the counter Module_Short_Count is greater than MODULE_SHORT, multiple output short circuit faults have occurred within a timing period, the output short circuit is established, and the shutdown flag Module_Stop_Flag is set; when the counter Module_Short_Count is less than MODULE_SHORT, the shutdown flag Module_Stop_Flag is cleared. It should be noted that the timing period TIMER_PREIOD is specifically confirmed according to the actual usage conditions. Generally, 1ms or 2ms is reasonable.
[0034] Further, it is determined whether the shutdown flag Module_Stop_Flag is set. When it is determined that the shutdown flag Module_Stop_Flag is set, the shutdown operation is performed.
[0035] The specific implementation methods of the present invention are as follows:
[0036] External interrupts are used to detect short-circuit signals. When the short-circuit signal is triggered, the external interrupt responds, and the PWM drive signal is immediately set to an invalid state in the external interrupt, and the flag HardWare_Short_Flag is set;
[0037] The detection of the above method is completed in a 40us control cycle:
[0038] In the first control cycle, it is detected that HardWare_Short_Flag is in the set state, and the timing flag Timer_Short_Flag is set. Because SoftWare_Short_Flag is not set, SoftWare_Short_Flag is set, and external interrupts are disabled, and the PWM drive signal is configured to an invalid state; because the timing flag is already set, the timer Timer_Index is accumulated at this time;
[0039] The second control cycle: HardWare_Short_Flag is set, SoftWare_Short_Flag is set, and the short-circuit fault recovery operation will be performed in this cycle: Clear HardWare_Short_Flag, clear SoftWare_Short_Flag, reconfigure the external interrupt enable, re-enable the PWM drive, and the counter Module_Short_Count accumulates, indicating that an output short-circuit fault has occurred. The timing flag has been set, and the timer Timer_Index continues to accumulate, and a short-circuit fault processing cycle is completed.
[0040] The value of TIMER_PREIOD is set to 25. When the value of the timer Timer_Index is greater than 25, that is, one timing cycle is 1ms, the value of MODULE_SHORT is set to 4, that is, within 1ms, if 4 or more short circuits occur, it means that the output is actually short-circuited, and the shutdown flag Module_Stop_Flag is set. If the number of short circuits within 1ms is less than 4 times, it means that it is a falsely triggered short-circuit operation, and the system continues to run without shutting down.
[0041] A digital power supply output short circuit fault processing device includes an analog-to-digital converter for receiving the output voltage of the digital power supply and comparing it with n reference values, and converting the comparison result into a digital error signal representing the error between the current output voltage of the digital power supply and the expected output voltage, where n≥3;
[0042] A digital compensation circuit receives the digital error signal to generate a digital duty cycle signal accordingly; the dynamic component of the digital duty cycle signal represents the error information between the current output voltage of the digital power supply and the expected output voltage;
[0043] The dynamic component of the digital duty cycle signal is transmitted to the analog-to-digital converter to adjust the value of all or part of the reference value accordingly to approach the desired output voltage;
[0044] The DPWM module includes an MCU and a PWM. According to the received digital duty cycle signal, the DPWM module generates a PWM control signal to control the switching action of the power switch in the digital power supply, thereby ensuring that the output voltage of the digital power supply is consistent with the expected output voltage, and when the output voltage of the digital power supply is inconsistent with the expected output voltage, the output voltage of the digital power supply is ensured to quickly recover to the expected output voltage.
[0045] Furthermore, the analog-to-digital converter includes a plurality of comparators, wherein a first input terminal of the comparator receives an output voltage of the digital power supply, and a second input terminal of the comparator receives a reference value.
[0046] Preferably, the PWM control signal output by the digital power supply control circuit is used to control the switching action of the power switch in the digital power supply.
[0047] The above is only a preferred embodiment of the present invention. It should be understood that the present invention is not limited to the form disclosed herein, and should not be regarded as excluding other embodiments, but can be used in various other combinations, modifications and environments, and can be modified within the scope of the concept described herein through the above teachings or the technology or knowledge of the relevant field. The changes and modifications made by those skilled in the art shall not deviate from the spirit and scope of the present invention, and shall be within the scope of protection of the claims attached to the present invention.
Claims
1. A method for handling a digital power supply output short circuit fault. Features: The following steps are involved: S1: define an output short-circuit signal, the output short-circuit signal is sent through a hardware comparator circuit, the MCU receives the short-circuit signal through a short-circuit signal pin, and the MCU marks the short-circuit signal state as HardWare_Short_Flag using an internal register; S2: Determine whether HardWare_Short_Flag is set. If the HardWare_Short_Flag flag is set, it means that a short circuit fault has been triggered. S3: Determine whether the timing flag Timer_Short_Flag is set. If Timer_Short_Flag=0, start the timing function. S4: Determine whether the short-circuit fault flag SoftWare_Short_Flag is set. When the short-circuit fault flag is 0, the short-circuit fault is detected for the first time. The SoftWare_Short_Flag short-circuit fault flag is in the set state, external interrupts are prohibited, and the PWM drive signal is configured to an invalid state. When the SoftWare_Short_Flag short-circuit fault flag is 1, the short-circuit fault is detected and processed. S5: Perform recovery operation on the short-circuit fault, clear the short-circuit fault flag SoftWare_Short_Flag, clear HardWare_Short_Flag, and enable the MCU short-circuit signal pin function, re-enable the PWM drive signal output, counter Module_Short_Count++, the counter records how many short-circuit faults have occurred within a period of time; Determine whether the timer is greater than the timing cycle TIMER_PREIOD, determine whether the counter Module_Short_Count is greater than MODULE_SHORT, MODULE_SHORT represents the maximum value of a short circuit that may occur in a timing cycle, and when the identification counter Module_Short_Count is greater than MODULE_SHORT, multiple output short circuit faults have occurred in a timing cycle, the output short circuit is established, and the shutdown flag Module_Stop_Flag is set; when the counter Module_Short_Count is less than MODULE_SHORT, the shutdown flag Module_Stop_Flag is cleared; S6: Determine whether the stop flag Module_Stop_Flag is set. When it is determined that the stop flag Module_Stop_Flag is set, enter the stop operation.
2. A method for processing a digital power supply output short circuit fault according to claim 1, Features: The step S1 also includes the following steps: the short-circuit signal acts on the PWM unit, and when a short-circuit fault occurs, the PWM immediately enters an invalid state.
