Fan control method and system, server and computer readable storage medium
The fan control method dynamically adjusts fan speed based on energy accumulation and temperature to prevent EFUSE chip overload, ensuring stable server operation and reducing design costs by avoiding high overcurrent protection settings.
Patent Information
- Application Number
- CN202411381242.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-30
- Publication Date
- 2024-12-13
AI Technical Summary
The issue of fans running at higher speeds during power-on startup in servers causes an instantaneous load that triggers the EFUSE chip's protection mechanism, leading to power loss in other components and potential chip damage, necessitating high overcurrent protection settings that increase design costs.
A fan control method that calculates startup cumulative energy and adjusts the duty cycle of the speed control signal to prevent excessive load on the EFUSE chip, ensuring stable system operation without increasing design costs by dynamically regulating fan speed based on energy accumulation and temperature.
Prevents the EFUSE chip's current limiting protection mechanism from being triggered, allowing normal fan startup and stable system operation, while maintaining compatibility with various fan specifications without additional design costs.
Smart Images

Figure CN119122835A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of servers, and in particular to a fan control method, system, server and computer-readable storage medium. Background Art
[0002] In the design of server boards, fan power supply control is a key link. The power-on startup of the fan is controlled by CPLD (Complex Programmable Logic Device). In order to enhance system security, an EFUSE (Electronic Fuse) chip is usually embedded between the fan and the power supply. CPLD controls the power-on startup of the fan by controlling the EFUSE action. The speed of the fan is controlled by the BMC (Baseboard Management Controller) to adjust the duty cycle of PWM. Since the BMC and CPLD do not interact, the fan may run at a higher speed during the power-on startup process, causing a large instantaneous load, triggering the protection mechanism of the EFUSE chip, and then causing other power supplies on the server board to lose power, causing abnormal startup of the entire machine.
[0003] At present, the overcurrent protection point of the EFUSE chip is usually set very high to adapt to fans of different specifications. However, unlimited increase in the overcurrent protection point may cause excessive pressure on the EFUSE chip, causing damage to the chip. In order to avoid this, the design specifications of the EFUSE chip need to be improved, which will undoubtedly increase the cost.
[0004] Therefore, how to provide a solution to the above technical problems is a problem that those skilled in the art need to solve at present. Summary of the invention
[0005] The object of the present invention is to provide a fan control method, system, server and computer-readable storage medium, which can prevent the current limiting protection mechanism of the target switch from being triggered, ensure that the fan can start normally, and thus ensure the stable operation of the entire system without increasing the design cost.
[0006] In order to solve the above technical problems, the present invention provides a fan control method, which is applied to a first controller. The fan control method includes:
[0007] When the first controller outputs a first speed control signal to the fan, the startup accumulated energy of the target switch disposed between the fan and the power supply is obtained according to the control cycle; the timing of the first controller outputting the first speed control signal to the fan is earlier than the timing of the second controller outputting the switch control signal to the target switch;
[0008] Comparing the startup accumulated energy obtained in the current control cycle with the startup limit threshold;
[0009] In response to the startup accumulated energy being greater than the startup limit threshold, a duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
[0010] Wherein, a sampling resistor is provided between the power supply of the fan and the target switch;
[0011] The process of obtaining the startup accumulated energy of the target switch disposed between the fan and the power supply according to the control cycle includes:
[0012] Acquire a first voltage at a first end of the target switch and a second voltage at a second end of the target switch in a current control cycle; the first end of the target switch is an end connected to the sampling resistor, and the second end of the target switch is an end connected to the fan;
[0013] Acquire a third voltage at a first end of the sampling resistor and a fourth voltage at a second end of the sampling resistor in the current control cycle; the first end of the sampling resistor is an end connected to the power supply, and the second end of the sampling resistor is an end connected to the target switch;
[0014] Obtaining the time length of the control cycle;
[0015] Calculate the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length;
[0016] Determining whether the current control cycle is the first control cycle;
[0017] If the current control cycle is the first control cycle, the startup instantaneous energy is used as the startup cumulative energy of the current control cycle;
[0018] If the current control cycle is not the first control cycle, the startup instantaneous energy of the current control cycle is added to the startup cumulative energy of the previous control cycle to obtain the startup cumulative energy of the current control cycle.
[0019] The process of calculating the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length includes:
[0020] calculating a first voltage difference between the first voltage and the second voltage;
[0021] calculating a second voltage difference between the third voltage and the fourth voltage;
[0022] Obtaining a sampling current according to the second voltage difference and the resistance value of the sampling resistor;
[0023] Obtaining instantaneous power based on the first voltage difference and the sampled current;
[0024] The startup instantaneous energy of the target switch in the current control cycle is calculated according to the instantaneous power and the time length.
[0025] Wherein, the sampling resistor is connected to an amplifier;
[0026] The process of calculating the second voltage difference between the third voltage and the fourth voltage includes:
[0027] A second voltage difference between the third voltage amplified by the amplifier and the fourth voltage amplified by the amplifier is calculated.
[0028] Wherein, the fan control method further includes:
[0029] Determine whether the target switch meets the full conduction condition in the current control cycle;
[0030] If so, adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value;
[0031] In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0032] If the target switch does not satisfy the full conduction condition in the current control cycle, in response to the startup accumulated energy being greater than the startup limit threshold, the duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
[0033] Wherein, after determining whether the target switch satisfies the full conduction condition in the current control cycle, the fan control method further includes:
[0034] If the target switch satisfies the full conduction condition in the current control cycle, determining whether the fan is in an over-speed regulation state in the current control cycle;
[0035] If yes, adjusting the duty cycle of the speed control signal output to the fan to an initial duty cycle, where the initial duty cycle is the duty cycle of the speed control signal output to the fan in the first control cycle;
[0036] The process of adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value includes:
[0037] If the fan is not in the overspeed state in the current control cycle, the duty cycle of the speed control signal output to the fan is adjusted based on the current temperature value.
[0038] In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0039] In response to the startup accumulated energy being greater than the startup limit threshold, acquiring an energy difference between the startup accumulated energy and the startup limit threshold;
[0040] determining a rotation speed reduction value corresponding to the energy difference;
[0041] In the current control cycle, a target duty cycle is determined based on the rotation speed reduction value, and a rotation speed control signal of the target duty cycle is output to the fan.
[0042] In order to solve the above technical problems, the present application also provides a fan control system, including:
[0043] Memory for storing computer programs;
[0044] A first controller, configured to implement the fan control steps as described in any one of the above when executing the computer program;
[0045] A target switch provided between the fan and the power supply;
[0046] The second controller is used to output a switch control signal to the target switch.
[0047] To solve the above technical problems, the present application also provides a server, comprising at least one fan and the fan control system as described above.
[0048] To solve the above technical problems, the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the fan control method as described in any one of the above are implemented.
[0049] The present application provides a fan control method, which obtains the startup cumulative energy of the target switch during the fan power-on process, compares the startup cumulative energy with the startup limit threshold of the target switch, and when the startup cumulative energy is greater than the startup limit threshold of the target switch, reduces the duty cycle of the speed control signal output to the fan to reduce the load at the rear end of the target switch, prevents the current limiting protection mechanism of the target switch from being triggered, ensures that the fan can start normally, and thus ensures the stable operation of the entire system. In addition, it is not necessary to increase the overcurrent protection point of the target switch to adapt to various types of fans, and no additional design cost is required. The present application also provides a fan control system, an electronic device, and a computer-readable storage medium, which have the same beneficial effects as the above-mentioned fan control method. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] In order to more clearly illustrate the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0051] Figure 1 A flow chart of the steps of a fan control method provided by the present invention;
[0052] Figure 2 A flowchart of another fan control method provided by the present invention;
[0053] Figure 3 A schematic structural diagram of a fan control device provided by the present invention;
[0054] Figure 4 A schematic diagram of the structure of a fan control system provided by the present invention;
[0055] Figure 5 This is a schematic diagram of the structure of a computer-readable storage medium provided by the present invention. DETAILED DESCRIPTION
[0056] The core of the present invention is to provide a fan control method, system, server and computer-readable storage medium, which can prevent the current limiting protection mechanism of the target switch from being triggered, ensure that the fan can start normally, and thus ensure the stable operation of the entire system without increasing the design cost.
[0057] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are 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.
[0058] First, please refer to Figure 1 The present application provides a fan control method, which is applied to a first controller. The fan control method includes:
[0059] S101: When the first controller outputs a first speed control signal to the fan, the startup accumulated energy of the target switch disposed between the fan and the power supply is obtained according to the control cycle; the timing of the first controller outputting the first speed control signal to the fan is earlier than the timing of the second controller outputting the switch control signal to the target switch;
[0060] In this embodiment, the function of the first controller may be implemented by a BMC, the function of the second controller may be implemented by a CPLD, and the target switch may specifically use an EFUSE chip.
[0061] When the first controller outputs the first speed control signal to the fan, in order to accurately obtain the startup cumulative energy of the target switch and accurately regulate the load at the rear end of the target switch, this embodiment uses the moment when the first controller outputs the first speed control signal to the fan as the starting moment of the first control cycle, samples the parameters of the target switch, and thus calculates the startup cumulative energy of the target switch. It can be understood that the startup cumulative energy is directly related to the overcurrent protection capability of the target switch.
[0062] Considering that the calculation of startup cumulative energy involves the process of energy change from the target switch being closed to being on, therefore, in this embodiment, the power-on timing of the first controller precedes the power-on timing of the second controller, which can ensure that the first controller can accurately obtain the parameters of the target switch before and after the switch, thereby improving the accuracy of calculating the startup cumulative energy. It can be understood that the parameters of the target switch before and after the switch specifically refer to the parameters of the target switch before receiving the switch control signal output by the second controller and before performing the conduction action, and the parameters of the target switch after receiving the switch control signal output by the second controller and responding to the switch control signal and performing the conduction action.
[0063] S102: Compare the startup accumulated energy obtained in the current control cycle with the startup limit threshold;
[0064] S103: In response to the startup accumulated energy being greater than the startup limit threshold, reducing the duty cycle of the speed control signal output to the fan in the current control cycle.
[0065] During the fan power-on startup process, in each control cycle, a judgment is made as to whether the startup cumulative energy obtained in the current control cycle is greater than the startup limit threshold. If the startup cumulative energy is greater than the startup limit threshold, the duty cycle of the speed control signal output to the fan is reduced in the current control cycle. Reducing the duty cycle can reduce the load at the rear end of the target switch, thereby reducing the current passing through the target switch, avoiding the target switch from triggering the protection mechanism due to overcurrent, and extending the service life of the target switch. In addition, by dynamically adjusting the duty cycle of the fan's speed control signal and reducing the current passing through the target switch, the startup characteristics of fans of different specifications can be adapted to improve compatibility. There is no need to set a higher overcurrent protection point for the target switch to adapt to fans of different specifications, and there is no need to increase the design cost. Among them, the startup limit threshold is set based on the characteristics of the target switch, and this embodiment does not limit its size.
[0066] It can be seen that in this embodiment, the startup accumulated energy of the target switch is obtained during the power-on process of the fan, and the startup accumulated energy is compared with the startup limit threshold of the target switch. When the startup accumulated energy is greater than the startup limit threshold of the target switch, the duty cycle of the speed control signal output to the fan is reduced to reduce the load at the rear end of the target switch to prevent the current limiting protection mechanism of the target switch from being triggered, thereby ensuring that the fan can start normally and thus ensuring the stable operation of the entire system. In addition, it is not necessary to increase the overcurrent protection point of the target switch to adapt to various types of fans, and there is no need to increase the design cost.
[0067] Based on the above embodiments:
[0068] In an exemplary embodiment, a sampling resistor is provided between the power supply of the fan and the target switch;
[0069] The process of obtaining the startup cumulative energy of the target switch disposed between the fan and the power supply according to the control cycle includes: obtaining a first voltage at a first end of the target switch and a second voltage at a second end of the target switch in the current control cycle; the first end of the target switch is an end connected to the sampling resistor, and the second end of the target switch is an end connected to the fan; obtaining a third voltage at the first end of the sampling resistor and a fourth voltage at the second end of the sampling resistor in the current control cycle; the first end of the sampling resistor is an end connected to the power supply, and the second end of the sampling resistor is an end connected to the target switch; obtaining the time length of the control cycle; calculating the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length; judging whether the current control cycle is the first control cycle; if the current control cycle is the first control cycle, the startup instantaneous energy is used as the startup cumulative energy of the current control cycle; if the current control cycle is not the first control cycle, the startup instantaneous energy of the current control cycle is added to the startup cumulative energy of the previous control cycle to obtain the startup cumulative energy of the current control cycle.
[0070] In this embodiment, it is considered that the target switch will have some restrictions on the power at startup during the startup process, and the power at startup is related to the voltage difference across the target switch and the current flowing through it. Therefore, in order to obtain the current flowing through the target switch, this embodiment further sets a sampling resistor between the target switch and the power supply. This embodiment calculates the instantaneous power by obtaining the voltage across the target switch and the voltage across the sampling resistor, thereby determining the pressure situation borne by the target switch, and thereby determining whether there is any abnormality in the startup of the target switch.
[0071] Specifically, a first voltage sampling point is added between the target switch and the power supply so that the first controller can obtain the first voltage, a second voltage sampling point is added between the target switch and the fan so that the first controller can obtain the second voltage, a third voltage sampling point is added between the sampling resistor and the power supply so that the first controller can obtain the third voltage, and a fourth voltage sampling point is added between the sampling resistor and the target switch so that the first controller can obtain the fourth voltage.
[0072] In each control cycle, the startup instantaneous energy is calculated based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length of the control cycle. By accumulating the startup instantaneous energy of each control cycle, the startup cumulative energy can be obtained, which is helpful to track the total energy consumption during the fan startup process. If the current control cycle is the first control cycle, then the startup instantaneous energy is used as the startup cumulative energy of the current control cycle. If the current control cycle is the i-th control cycle, i=2, 3..., the startup instantaneous energy of the previous i control cycles including itself is accumulated to obtain the startup cumulative energy of the i-th control cycle. For the convenience of calculation, the startup instantaneous energy of the i-th control cycle and the startup cumulative energy of the i-1-th control cycle are added. It can be understood that by monitoring the startup cumulative energy, measures (such as reducing the duty cycle) can be taken before the energy accumulation exceeds the safety threshold, thereby preventing overheating and overcurrent. The solution of this embodiment does not depend on the specific model or specification of the fan, and can be applied to a variety of fans, thereby improving the compatibility of the system.
[0073] In an exemplary embodiment, the process of calculating the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length includes: calculating the first voltage difference between the first voltage and the second voltage; calculating the second voltage difference between the third voltage and the fourth voltage; obtaining the sampling current based on the second voltage difference and the resistance value of the sampling resistor; obtaining the instantaneous power based on the first voltage difference and the sampling current; and calculating the startup instantaneous energy of the target switch in the current control cycle based on the instantaneous power and the time length.
[0074] In this embodiment, in the first controller, the first voltage difference between the first voltage and the second voltage is calculated, and then the current flowing through the target switch is converted according to the second voltage difference and the resistance value of the sampling resistor. The instantaneous power can be obtained by multiplying the first voltage difference and the current, and the energy accumulated in one cycle can be obtained by multiplying the instantaneous power by the time length.
[0075] In an exemplary embodiment, the sampling resistor is connected to an amplifier;
[0076] The process of calculating the second voltage difference between the third voltage and the fourth voltage includes:
[0077] A second voltage difference between the third voltage amplified by the amplifier and the fourth voltage amplified by the amplifier is calculated.
[0078] In this embodiment, the sampling resistor can be selected as a precision resistor. Since the resistance of the precision resistor is small, usually about 1mΩ, the voltage signal it brings will also be relatively small. In order to be able to more accurately detect the voltage across the sampling resistor, an analog amplifier is added between the first controller and the sampling resistor. The third voltage and the fourth voltage are amplified by the amplifier. In this way, the voltage monitoring signal can be more accurate and a more accurate current change flowing through the target switch can be obtained.
[0079] Combination Figure 2 , the processing flow of the above-mentioned first controller is explained. The first controller performs voltage sampling, converts the third voltage and the fourth voltage collected by the amplifier into current, makes a difference between the first voltage and the second voltage, multiplies the voltage and the current to obtain instantaneous power and multiplies it by the time length of the control cycle to obtain the startup instantaneous energy, obtains the startup cumulative energy of the previous control cycle, adds the startup instantaneous energy and the startup cumulative energy, and then compares them with the startup limit threshold, and then waits for the voltage sampling of the next control cycle. If it exceeds, the duty cycle of the speed control signal output to the fan is reduced. If it does not exceed, the voltage sampling of the next control cycle is entered.
[0080] In an exemplary embodiment, the fan control method further includes:
[0081] Determine whether the target switch meets the full conduction condition in the current control cycle;
[0082] If so, adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value;
[0083] In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0084] If the target switch does not meet the full conduction condition in the current control cycle, in response to the startup accumulated energy being greater than the startup limit threshold, the duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
[0085] In this embodiment, it is judged whether the target starts to be fully turned on. The fully turned-on condition includes that the input voltage of the fan reaches the target voltage value corresponding to the normal level, and the voltages at both ends of the target switch are consistent, so as to jointly judge whether the target switch is fully turned on. If the input voltage of the fan reaches the target voltage value corresponding to the normal level, and the voltages at both ends of the target switch are consistent, it is determined that the target switch meets the fully turned-on condition in the current control cycle. When the target switch is fully turned on, it is determined that the fan is normally powered on and started. Then, the speed of the fan is no longer regulated based on the control logic of using the accumulated energy at startup, but the speed of the fan is regulated by the current temperature, that is, the first controller regulates the speed of the fan according to the temperature control mode. If the target switch does not meet the fully turned-on condition in the current control cycle, that is, the target switch is not fully turned on, the first controller still regulates the speed of the fan according to the energy control mode, and the energy control mode is the control mode using the accumulated energy at startup. With the solution of this embodiment, after determining that the fan is normally powered on and started, the first controller regulates the speed of the fan based on the current temperature value, which can reduce the high-speed operation of the fan under unnecessary circumstances, reduce wear, and extend the service life of the fan.
[0086] In an exemplary embodiment, after determining whether the target switch meets the full conduction condition in the current control cycle, the fan control method further includes:
[0087] If the target switch meets the full conduction condition in the current control cycle, it is determined whether the fan is in an over-speed regulation state in the current control cycle;
[0088] If so, the duty cycle of the speed control signal output to the fan is adjusted to an initial duty cycle, where the initial duty cycle is the duty cycle of the speed control signal output to the fan in the first control cycle;
[0089] The process of adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value includes:
[0090] If the fan is not in an overspeed state in the current control cycle, the duty cycle of the speed control signal output to the fan is adjusted based on the current temperature value.
[0091] In this embodiment, after determining that the fan is fully started, it is first determined whether the fan is in an over-speed state. The over-speed state here means that the duty cycle of the fan speed signal currently determined based on the accumulated energy at startup is greater than the duty cycle of the fan speed signal determined based on the current temperature value. In this case, the duty cycle of the speed control signal output to the fan is first adjusted to the initial duty cycle, thereby avoiding the possibility that the duty cycle of the fan speed signal is directly adjusted according to the current temperature value, which may cause a sharp change in the fan speed. Using the duty cycle determined at startup can provide a smooth transition and avoid impact on the motor.
[0092] In an exemplary embodiment, in response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0093] In response to the startup accumulated energy being greater than the startup limit threshold, obtaining an energy difference between the startup accumulated energy and the startup limit threshold;
[0094] determining a speed reduction value corresponding to the energy difference;
[0095] In the current control cycle, a target duty cycle is determined based on the rotation speed reduction value, and a rotation speed control signal of the target duty cycle is output to the fan.
[0096] In this embodiment, when the duty cycle of the speed control signal output to the fan is determined, the energy difference between the startup cumulative energy and the startup limit threshold can be determined first. This difference reflects the degree to which the energy accumulation exceeds the safety limit when the fan is started. The larger the energy difference, the more serious the degree to which the startup cumulative energy exceeds the threshold, and therefore the fan speed needs to be reduced to a greater extent. A corresponding speed reduction value is determined based on the energy difference, and the target duty cycle is determined based on the speed reduction value. The larger the speed reduction value, the lower the target duty cycle should be, so as to achieve a greater speed reduction. The accuracy of each speed regulation is improved, and a speed control signal with a target duty cycle is output to the fan to reduce the fan speed, thereby reducing the load at the rear end of the target switch to reduce the current flowing through the target switch.
[0097] As another optional embodiment, by directly associating the energy difference and the speed reduction value, the fan speed can be controlled more accurately to avoid excessive or unnecessary speed adjustment. The correspondence between each speed reduction value, the energy difference and the target duty cycle can be obtained in advance. When determining the target duty cycle, the target duty cycle can be determined directly based on the current energy difference and the above correspondence, thereby reducing the time required for real-time calculation, thereby speeding up the response speed to the fan speed adjustment and avoiding inaccurate control due to real-time calculation errors.
[0098] In this embodiment, the current limiting protection is triggered during the EFUSE load startup process, which causes the board to power off. In terms of hardware, the BMC on the original board is used to implement this circuit. Only the voltage sampling circuit needs to be added, which will not significantly increase the cost and the complexity of the design. This avoids the original situation where the current limiting point is simply increased, but all fans cannot be covered, resulting in power failure. At the same time, it can also avoid the burning of the protection chip due to setting too large a protection point. By testing the adaptability of various fans, it can be adjusted adaptively according to various fans, which greatly reduces the labor cost in the early stage of research and development to test whether the protection point is suitable.
[0099] Second, please refer to Figure 3 , Figure 3 This is a structural schematic diagram of a fan control device provided by the present invention, the fan control device comprises:
[0100] The acquisition module 11 is used for acquiring the startup accumulated energy of the target switch disposed between the fan and the power supply according to the control cycle when the first controller outputs the first speed control signal to the fan; the timing of the first controller outputting the first speed control signal to the fan is earlier than the timing of the second controller outputting the switch control signal to the target switch;
[0101] A judgment module 12 is used to compare the startup cumulative energy obtained in the current control cycle with the startup limit threshold;
[0102] The control module 13 is configured to reduce the duty cycle of the speed control signal output to the fan in a current control cycle in response to the startup accumulated energy being greater than a startup limit threshold.
[0103] In an exemplary embodiment, a sampling resistor is provided between the power supply of the fan and the target switch;
[0104] The process of obtaining the startup accumulated energy of the target switch disposed between the fan and the power supply according to the control cycle includes:
[0105] Acquire a first voltage at a first end of a target switch and a second voltage at a second end of the target switch in a current control cycle; the first end of the target switch is an end connected to a sampling resistor, and the second end of the target switch is an end connected to a fan;
[0106] Acquire a third voltage at a first end of the sampling resistor and a fourth voltage at a second end of the sampling resistor in a current control cycle; the first end of the sampling resistor is an end connected to a power supply, and the second end of the sampling resistor is an end connected to a target switch;
[0107] Get the length of the control cycle;
[0108] Calculate the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length;
[0109] Determine whether the current control cycle is the first control cycle;
[0110] If the current control cycle is the first control cycle, the startup instantaneous energy is used as the startup cumulative energy of the current control cycle;
[0111] If the current control cycle is not the first control cycle, the startup instantaneous energy of the current control cycle is added to the startup cumulative energy of the previous control cycle to obtain the startup cumulative energy of the current control cycle.
[0112] In an exemplary embodiment, the process of calculating the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length includes:
[0113] calculating a first voltage difference between the first voltage and the second voltage;
[0114] calculating a second voltage difference between the third voltage and the fourth voltage;
[0115] Obtaining a sampling current according to the second voltage difference and the resistance value of the sampling resistor;
[0116] Obtaining instantaneous power based on the first voltage difference and the sampled current;
[0117] The startup instantaneous energy of the target switch in the current control cycle is calculated based on the instantaneous power and time length.
[0118] In an exemplary embodiment, the sampling resistor is connected to an amplifier;
[0119] The process of calculating the second voltage difference between the third voltage and the fourth voltage includes:
[0120] A second voltage difference between the third voltage amplified by the amplifier and the fourth voltage amplified by the amplifier is calculated.
[0121] In an exemplary embodiment, the fan control device further includes:
[0122] A first judgment module is used to judge whether the target switch meets the full conduction condition in the current control cycle, and if so, adjust the duty cycle of the speed control signal output to the fan based on the current temperature value;
[0123] In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0124] If the target switch does not meet the full conduction condition in the current control cycle, in response to the startup accumulated energy being greater than the startup limit threshold, the duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
[0125] In an exemplary embodiment, after determining whether the target switch meets the full conduction condition in the current control cycle, the fan control device further includes:
[0126] The second judgment module is used to judge whether the fan is in an over-speed regulation state in the current control cycle if the target switch meets the full conduction condition in the current control cycle, and if so, adjust the duty cycle of the speed control signal output to the fan to the initial duty cycle, and the initial duty cycle is the duty cycle of the speed control signal output to the fan in the first control cycle;
[0127] The process of adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value includes:
[0128] If the fan is not in an overspeed state in the current control cycle, the duty cycle of the speed control signal output to the fan is adjusted based on the current temperature value.
[0129] In an exemplary embodiment, in response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes:
[0130] In response to the startup accumulated energy being greater than the startup limit threshold, obtaining an energy difference between the startup accumulated energy and the startup limit threshold;
[0131] determining a speed reduction value corresponding to the energy difference;
[0132] In the current control cycle, a target duty cycle is determined based on the rotation speed reduction value, and a rotation speed control signal of the target duty cycle is output to the fan.
[0133] Third, please refer to Figure 4 , the present application also provides a fan control system, comprising:
[0134] Memory for storing computer programs;
[0135] A first controller 21, configured to implement any of the above fan control steps when executing a computer program;
[0136] A target switch 22 disposed between the fan and the power supply;
[0137] The second controller 23 is used to output a switch control signal to the target switch 22 .
[0138] The fan control system further includes a sampling resistor 24 disposed between the target switch 22 and the power supply, and an amplifier 25 connected to the sampling resistor 24 .
[0139] For an introduction to a fan control system provided in the present application, please refer to the above-mentioned embodiment, and the present application will not go into details here.
[0140] A fan control system provided in the present application has the same beneficial effects as the above-mentioned fan control method.
[0141] In a fourth aspect, the present application also provides a server, comprising at least one fan, and the fan control system as described above.
[0142] For an introduction to a server provided in this application, please refer to the above embodiment, and this application will not go into details here.
[0143] The server provided in the present application has the same beneficial effects as the above-mentioned fan control method.
[0144] Fifth, please refer to Figure 5 The present application also provides a computer-readable storage medium 30, on which a computer program 31 is stored. When the computer program 31 is executed by a processor, the steps of the fan control method described in any of the above embodiments are implemented.
[0145] For an introduction to a computer-readable storage medium provided in the present application, please refer to the above-mentioned embodiments, and the present application will not go into details here.
[0146] A computer-readable storage medium provided in the present application has the same beneficial effects as the above-mentioned fan control method.
[0147] In a sixth aspect, the present application further provides a computer program product, including a computer program / instruction, which, when executed by a processor, implements the steps of the fan control method described in any one of the embodiments.
[0148] For an introduction to a computer program product provided by the present application, please refer to the above embodiments, and the present application will not go into details here.
[0149] A computer program product provided in the present application has the same beneficial effects as the above-mentioned fan control method.
[0150] It should also be noted that, in this specification, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprises", "comprising" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the statement "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.
[0151] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A fan control method, It is characterized in that Applied to the first controller, the fan control method includes: When the first controller outputs a first speed control signal to the fan, the startup accumulated energy of the target switch disposed between the fan and the power supply is obtained according to the control cycle; the timing of the first controller outputting the first speed control signal to the fan is earlier than the timing of the second controller outputting the switch control signal to the target switch; Comparing the startup accumulated energy obtained in the current control cycle with the startup limit threshold; In response to the startup accumulated energy being greater than the startup limit threshold, a duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
2. The fan control method according to claim 1, It is characterized in that A sampling resistor is provided between the power supply of the fan and the target switch; The process of obtaining the startup accumulated energy of the target switch disposed between the fan and the power supply according to the control cycle includes: Acquire a first voltage at a first end of the target switch and a second voltage at a second end of the target switch in a current control cycle; the first end of the target switch is an end connected to the sampling resistor, and the second end of the target switch is an end connected to the fan; Acquire a third voltage at a first end of the sampling resistor and a fourth voltage at a second end of the sampling resistor in the current control cycle; the first end of the sampling resistor is an end connected to the power supply, and the second end of the sampling resistor is an end connected to the target switch; Obtaining the time length of the control cycle; Calculate the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length; Determining whether the current control cycle is the first control cycle; If the current control cycle is the first control cycle, the startup instantaneous energy is used as the startup cumulative energy of the current control cycle; If the current control cycle is not the first control cycle, the startup instantaneous energy of the current control cycle is added to the startup cumulative energy of the previous control cycle to obtain the startup cumulative energy of the current control cycle.
3. The fan control method according to claim 2, It is characterized in that The process of calculating the startup instantaneous energy of the target switch in the current control cycle based on the first voltage, the second voltage, the third voltage, the fourth voltage and the time length includes: calculating a first voltage difference between the first voltage and the second voltage; calculating a second voltage difference between the third voltage and the fourth voltage; Obtaining a sampling current according to the second voltage difference and the resistance value of the sampling resistor; Obtaining instantaneous power based on the first voltage difference and the sampled current; The startup instantaneous energy of the target switch in the current control cycle is calculated according to the instantaneous power and the time length.
4. The fan control method according to claim 3, It is characterized in that The sampling resistor is connected to an amplifier; The process of calculating the second voltage difference between the third voltage and the fourth voltage includes: A second voltage difference between the third voltage amplified by the amplifier and the fourth voltage amplified by the amplifier is calculated.
5. The fan control method according to claim 2, It is characterized in that The fan control method further includes: Determine whether the target switch meets the full conduction condition in the current control cycle; If so, adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value; In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes: If the target switch does not satisfy the full conduction condition in the current control cycle, in response to the startup accumulated energy being greater than the startup limit threshold, the duty cycle of the speed control signal output to the fan is reduced in the current control cycle.
6. The fan control method according to claim 5, It is characterized in that After determining whether the target switch satisfies a full conduction condition in the current control cycle, the fan control method further includes: If the target switch satisfies the full conduction condition in the current control cycle, determining whether the fan is in an over-speed regulation state in the current control cycle; If yes, adjusting the duty cycle of the speed control signal output to the fan to an initial duty cycle, where the initial duty cycle is the duty cycle of the speed control signal output to the fan in the first control cycle; The process of adjusting the duty cycle of the speed control signal output to the fan based on the current temperature value includes: If the fan is not in the overspeed state in the current control cycle, the duty cycle of the speed control signal output to the fan is adjusted based on the current temperature value.
7. The fan control method according to any one of claims 1 to 6, It is characterized in that In response to the startup accumulated energy being greater than the startup limit threshold, the process of reducing the duty cycle of the speed control signal output to the fan in the current control cycle includes: In response to the startup accumulated energy being greater than the startup limit threshold, acquiring an energy difference between the startup accumulated energy and the startup limit threshold; determining a rotation speed reduction value corresponding to the energy difference; In the current control cycle, a target duty cycle is determined based on the rotation speed reduction value, and a rotation speed control signal of the target duty cycle is output to the fan.
8. A fan control system, It is characterized in that include: Memory for storing computer programs; A first controller, configured to implement the fan control steps as described in any one of claims 1 to 7 when executing the computer program; A target switch provided between the fan and the power supply; The second controller is used to output a switch control signal to the target switch.
9. A server, It is characterized in that Includes at least one fan, and the fan control system as claimed in claim 8.
10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the fan control method according to any one of claims 1 to 7 are implemented.
