Battery power supply method and device, storage medium and electronic equipment
By intelligently controlling the access and disconnection of the battery pack unit, the problems of short life, poor charging safety and low charging efficiency of the BBU module lithium battery are solved, and a safer and more efficient battery charging and power supply process is achieved.
Patent Information
- Application Number
- CN202510120739.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-24
- Publication Date
- 2025-05-13
AI Technical Summary
In the prior art, the lithium battery of the BBU module has problems such as short life, poor charging safety and low charging efficiency, especially frequent entry into the charging process, which leads to bulging.
The first circuit is formed in series by the power module, the battery backup module and the power consumption module in the storage server to supply power to the storage server; in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets specific conditions, the battery pack unit is controlled to access or disconnect the first circuit to realize intelligent control of charging and power supply.
It avoids frequent entry into the charging process, reduces the charging frequency, reduces the risk of battery bulging, improves the service life of the battery, and solves the problems of poor charging safety and low charging efficiency.
Smart Images

Figure CN119995093A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of battery power supply technology, and specifically, to a battery power supply method and device, a storage medium, and an electronic device. Background Art
[0002] For storage servers, when performing a large number of write operations, in order to improve write performance, data is usually written to the cache. When the write pressure is reduced or the cache is full, the cache is written to the hard disk. When the server loses power unexpectedly, the data in the cache will be lost. Therefore, in order to improve the read and write performance of the entire machine and improve data security, it is necessary to configure power-off protection measures for the RAID card. When the server loses power unexpectedly, the battery pack supplies power to the cache, so that the data is stored in the cache, which can usually be maintained for dozens of hours; when the server is operating normally, the entire machine charges the battery through the power supply to maintain its power.
[0003] BBU usually uses lithium batteries as the power storage unit, which has the problem of short lifespan. Traditional BBU modules need to shut down the server and power off when they are maintained and replaced, which increases the difficulty and cost of maintenance. Moreover, after the lithium-ion battery is charged to the rated voltage, some empty capacity will not be fully filled. In the process of filling this empty capacity, the battery cell will be deformed, which may cause bulging. In other words, there are technical problems in the related technology that frequent charging process leads to poor charging safety and low charging efficiency.
[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0005] The embodiments of the present application provide a battery power supply method and device, a storage medium and an electronic device to at least solve the technical problem in the related art that frequent charging process leads to poor charging safety and low charging efficiency.
[0006] According to one embodiment of the present application, a battery power supply method is provided, comprising: forming a first circuit by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first circuit is used to power the storage server; in response to a charging unit in the battery backup module detecting that a current state of a battery pack unit satisfies a first state condition, controlling the battery pack unit to be connected to the first circuit by a control unit in the battery backup module to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first circuit and a second circuit, and the second circuit is formed by connecting the charging unit, the control unit, and the battery pack unit in series in the battery backup module; in response to the charging unit detecting that a current state of the battery pack unit satisfies a second state condition, controlling the battery pack unit to disconnect from the first circuit by the control unit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through a third circuit when the power module is offline, and the third circuit is formed by connecting the battery pack unit, the charging unit, the power module, and the control unit in series.
[0007] According to another aspect of an embodiment of the present application, a battery power supply device is also provided, including: a first determination unit, which forms a first circuit by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first circuit is used to power the storage server; a first power supply unit, in response to a charging unit in the battery backup module detecting that a current state of a battery pack unit satisfies a first state condition, controls the battery pack unit to be connected to the first circuit through a control unit in the battery backup module to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first circuit and a second circuit, and the second circuit is formed by connecting the charging unit, the control unit, and the battery pack unit in series in the battery backup module; a second power supply unit, in response to the charging unit detecting that a current state of a battery pack unit satisfies a second state condition, controls the battery pack unit to disconnect from the first circuit through the control unit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through a third circuit when the power module is offline, and the third circuit is formed by connecting the battery pack unit, the charging unit, the power module, and the control unit in series.
[0008] Optionally, the power supply device of the above-mentioned battery includes a connection module, and the control unit includes an NMOS element, a first PMOS element and a second PMOS element, the first drain of the first PMOS element is connected to the first circuit, the first source of the first PMOS element is electrically connected to the second source of the second PMOS element, the second drain of the second PMOS element is electrically connected to the battery pack unit, the first gate of the first PMOS element, the second gate of the second PMOS element and the third drain of the NMOS element are electrically connected, the third gate of the NMOS element is electrically connected to the charging unit, and the third source of the NMOS element is electrically connected to the battery pack unit.
[0009] Optionally, the above-mentioned first determination unit is also used to: when the battery pack detection unit detects that the battery pack unit is offline, in the battery pack detection unit, turn on the MOSFET switch on the battery detection pin to obtain a first reference circuit; send a first prompt information to the charging unit through the first reference circuit, wherein the first prompt information is used to indicate the offline state of the battery pack; when the battery pack detection unit detects that the battery pack unit is online, in the battery pack detection unit, turn off the MOSFET switch on the battery detection pin to obtain a second reference circuit; send a second prompt information to the charging unit through the second reference circuit, wherein the first prompt information is used to indicate the online state of the battery pack.
[0010] Optionally, the above-mentioned first power supply unit is also used to: when the current power of the battery pack unit is lower than the recharging threshold, determine that the current state of the battery pack unit meets the first state condition; send a first control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the first control signal is used to control the NMOS element to be turned on; when the NMOS element is turned on, determine that the battery pack unit is connected to the first loop according to the electrical connection relationship between the NMOS element, the first PMOS element and the second PMOS element.
[0011] Optionally, the second power supply unit is also used to: determine that the current state of the battery pack unit satisfies the second state condition when the charging current of the battery pack unit is lower than the charging termination threshold and the charging voltage is higher than the recharging threshold; send a second control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the second control signal is used to control the NMOS element to shut down; and determine that the battery pack unit is disconnected from the first circuit based on the electrical connection relationship between the first source of the first PMOS element and the second source of the second PMOS element when the NMOS element is turned off.
[0012] Optionally, the first power supply unit further includes a switching module, which is used to obtain the current power of the battery pack unit under a target risk scenario, wherein the target risk scenario is to determine, based on a deep learning algorithm, that the power supply module performs a power supply operation that satisfies an abnormal execution condition; when the current power does not reach a target power threshold, a first circuit is formed in response to a first charging instruction, wherein the target power threshold is a full power value of the battery pack unit, and the first charging instruction is used to instruct the control unit in the battery backup module to obtain the first circuit based on the electrical connection relationship between the NMOS element, the first PMOS element, and the second PMOS element; the battery pack unit is charged through the power module; when it is monitored that the battery pack unit only performs a discharge operation within a target time period, and the battery pack unit has a power value lower than a reference power threshold within a target monitoring time period, a first circuit is formed according to a second charging instruction, wherein the reference power threshold is determined based on a historical charging power value of the battery pack unit, the second charging instruction is a target signal instruction transmitted by the BMC unit through a target communication link using a target communication protocol, the target communication protocol is a signal transmission protocol between the BMC unit and the control unit, and the target signal instruction is used to instruct the control unit to control the NMOS element to conduct to form the first circuit; the battery pack unit is charged through the power module.
[0013] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned battery power supply method when running.
[0014] According to another aspect of the embodiments of the present application, a computer program product or a computer program is provided, the computer program product or the computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above battery power supply method.
[0015] According to another aspect of the embodiments of the present application, there is further provided an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the battery power supply method through the computer program.
[0016] Through the present application, firstly, a first circuit is formed by connecting a power module, a battery backup module, and a power module in a storage server in series, so as to form a basic power supply circuit to power the storage server; further, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first circuit to form a first circuit, so as to charge the battery pack through the power module; in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit; thus, the frequent entry into the charging process is avoided, the charging frequency is reduced, the risk of battery bulging is reduced, and the service life is increased, thereby solving the technical problem in the related art that frequent entry into the charging process leads to poor charging safety and low charging efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0018] Figure 1 It is a hardware structure block diagram of a server device of a battery power supply method according to an embodiment of the present application;
[0019] Figure 2 is a flow chart of a battery power supply method according to an embodiment of the present application;
[0020] Figure 3 is a system schematic diagram of a battery power supply method according to an embodiment of the present application;
[0021] Figure 4 is a schematic diagram of a battery power supply method according to an embodiment of the present application;
[0022] Figure 5 is a circuit diagram of a battery power supply method according to an embodiment of the present application;
[0023] Figure 6 is a circuit diagram of another battery power supply method according to an embodiment of the present application;
[0024] Figure 7 is a circuit diagram of another battery power supply method according to an embodiment of the present application;
[0025] Figure 8 is a schematic structural diagram of a battery power supply device according to an embodiment of the present application;
[0026] Fig. 9 It is a schematic structural diagram of a battery-powered electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0027] The embodiments of the present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0028] It should be noted that the terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0029] The following is a description of the signals that appear in this application:
[0030] PSU_12V: The 12V constant voltage power output by the PSU unit serves as the total input power for the motherboard and BQ25770 unit.
[0031] CHG_SMBus: The communication link between BMC and BQ25770 includes two signals, CHG_SMBus_SCL and CHG_SMBus_SDA, which are used as clock and data transmission respectively, using SMBus protocol. BMC controls BQ25770 through this group of signals and reads its register information.
[0032] PSU_I2C: The communication link between the PSU and the motherboard BMC, including two signals, PSU_SCL and PSU_SDA, which are used for clock and data transmission respectively.
[0033] CHRG_OK: Charging status signal controlled by BQ25770. When the PSU is in place and working normally (i.e. PSU_12V is normally input to BQ25770), if the charging process begins, BQ25770 controls the signal to be pulled high. When charging is completed or the PSU fails to supply power, BQ25770 actively pulls down the signal for a certain period of time and then recovers to notify the BMC that charging has been terminated. In addition, this signal can also be used to report interrupts such as overvoltage protection, overcurrent protection, and other problems.
[0034] PROCHOT_N: The interrupt signal that BQ25770 reports to BMC when PSU fails. This signal is high when the system is working normally. When a failure occurs, this signal is pulled low until BMC reads the problem information.
[0035] CELL_BATPRES: Battery presence detection signal. When the battery pack unit is in place, the signal is pulled high, and the BQ25770 will perform the charging process based on the current battery power information; when the battery pack unit is unplugged, the signal is pulled low, at which point the BQ25770 will actively turn off the BATFET and stop the charging process.
[0036] BATDRV: BATFET drive signal, sent by BQ25770. When the signal is high, the BATFET unit is turned on, and the battery pack unit is connected to the VSYS circuit, which can supply power to the system or the charging unit can charge the battery pack unit. When the signal is low, the BATFET unit is turned off, the battery pack unit is disconnected from the VSYS circuit, and can no longer supply power to the system, and the charging unit cannot charge the battery pack unit.
[0037] VBAT: The positive voltage output by the battery pack unit.
[0038] VSYS: system voltage output by BQ25770.
[0039] The method embodiments provided in the embodiments of the present application can be executed in a server device or a similar computing device. Taking running on a server device as an example, Figure 1 FIG. 1 is a hardware structure diagram of a server device of a battery power supply method according to an embodiment of the present application. Figure 1 As shown, the server device may include one or more ( Figure 1 Only one is shown in the figure) a processor 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data, wherein the above-mentioned server device may also include a transmission device 106 and an input / output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above server device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.
[0040] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the battery power supply method in the embodiment of the present application. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, to implement the above method. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the server device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0041] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the server device. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0042] As an optional implementation, Figure 2 As shown, the power supply method of the battery includes:
[0043] S202, forming a first loop by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server;
[0044] S204, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first loop and a second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series;
[0045] S206, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through the third circuit when the power module is offline, and the third circuit is formed by the battery pack unit, the charging unit, the power module and the control unit connected in series.
[0046] In an optional implementation, it should be noted that in the above step S202, the first loop is formed by connecting the power module, the battery backup module, and the power module in the storage server in series. Figure 3As shown, the power supply module (PSU) receives AC power or DC power input through a power cable. The PSU contains a power converter, such as an AC / DC converter (AC to DC) or a DC / DC converter (DC to DC). These converters convert the input AC power into the voltage level required by the power consumption module. The power-on process of the server is managed by the baseboard management controller (BMC) in the battery backup module (BBU). After the BMC detects the stable power provided by the PSU, it will start the system power-on process and send a power-on signal to each component. The storage server (as shown in the schematic diagram) is powered on through the first circuit. Figure 3 The motherboard in the server is used to supply power to ensure smooth startup and operation of the server.
[0047] Optionally, in the above step S204, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit satisfies the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first circuit to form a first circuit to charge the battery pack through the power module, wherein the first circuit includes a first circuit and a second circuit, and the second circuit is formed by the charging unit, the control unit and the battery pack unit in the battery backup module being connected in series.
[0048] It should be noted that the charging unit may be BQ25770, as shown in the schematic diagram Figure 3 The charging unit on the BBU is BQ25770, and the above-mentioned first state condition can be specifically: the voltage of the battery presence detection pin CELL_BATPRES is not 0, CHRG_OK is at a high level, and the battery pack unit power is lower than the recharging threshold.
[0049] The above control unit may be a schematic diagram Figure 3 The BATFET unit is a bidirectional switch circuit composed of a group of MOS tubes, which is used to control the on-off between the VSYS loop and the battery pack unit. The specific schematic diagram is as follows Figure 4 As shown, VSYS is connected to the BQ25770 output and can be used as the battery charging voltage. BATDRV is the signal that BQ25770 controls the on / off of the circuit. Q1 is an NMOS, which acts as an inverter. Q2 and Q3 are two PMOS. The sources of Q2 and Q3 are connected together as a switch. R1 is a bleed resistor. When the BATDRV signal from BQ25770 is high, Q1 is turned on, and then Q2 and Q3 are turned on. The above battery pack unit (i.e. Figure 4The VBAT of the Battery in the circuit is connected to the VSYS circuit, which can supply power to the system or charge the battery pack unit by BQ25770; when the BATDRV signal is low, the Q1 unit is turned off, and Q2 and Q3 are not turned on. Since the two PMOS sources are connected, the body diode will block the leakage of VBAT and VSYS to the other side. At this time, the battery pack unit is disconnected from the VSYS circuit and can no longer supply power to the system, and the charging unit cannot charge the battery pack unit.
[0050] It should be noted that the recharge threshold refers to the battery voltage when the battery is charged from low power to the point where BQ25770 considers charging complete, and the recharge threshold refers to the voltage value at which BQ25770 restarts the charging process after the voltage (i.e., the recharge threshold) drops a certain value from the voltage when the battery is fully charged or stopped charging. For example: When three lithium batteries are connected in series, the typical voltage is 3*4.2V=12.6V. If this voltage is set as the recharge threshold, that is, when the battery is charged from low voltage to the point where the battery voltage reaches 12.6V, the charging stops; when the recharge threshold is set to 600mV, the battery that was previously stopped will start a new charging process after the voltage drops by 600mV, that is, when it is lower than 12.6V-0.6V=12V; when the recharge threshold is set to 200mV, the battery that was previously stopped will start a new charging process after the voltage drops by 200mV, that is, when it is lower than 12.6V-0.2V=12.4V.
[0051] Further, in the above step S206, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through the third circuit when the power module is offline, and the third circuit is formed in series by the battery pack unit, the charging unit, the power module and the control unit. Specifically, the above second state condition can be that the charging current is lower than the termination threshold and the charging voltage is higher than the recharging threshold, that is, when charging is completed, the battery pack is disconnected.
[0052] Through the present application, firstly, a first circuit is formed by connecting a power module, a battery backup module, and a power module in a storage server in series, so as to form a basic power supply circuit to power the storage server; further, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first circuit to form a first circuit, so as to charge the battery pack through the power module, thereby ensuring that the battery pack can be restored in time when the battery is low, and providing backup power support for the server in an emergency; in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit; thus, it is achieved that frequent entry into the charging process is avoided, the charging frequency is reduced, the risk of battery bulging is reduced, and the service life is increased, thereby solving the technical problem in the related art that frequent entry into the charging process leads to poor charging safety and low charging efficiency.
[0053] In an optional embodiment, the control unit includes an NMOS element, a first PMOS element and a second PMOS element, the first drain of the first PMOS element is connected to the first loop, the first source of the first PMOS element is electrically connected to the second source of the second PMOS element, the second drain of the second PMOS element is electrically connected to the battery pack unit, the first gate of the first PMOS element, the second gate of the second PMOS element and the third drain of the NMOS element are electrically connected, the third gate of the NMOS element is electrically connected to the charging unit, and the third source of the NMOS element is electrically connected to the battery pack unit.
[0054] It should be noted that the source is the starting point of the current in the MOSFET. In N-channel MOSFET, the source is usually connected to a low potential, such as the ground line (GND) of the circuit or the negative pole of the power supply; in P-channel MOSFET, the source is connected to a high potential, such as the positive pole of the power supply. The source is connected to the channel region through the N or P type semiconductor material of the MOSFET, and is the source of electrons or holes in the channel region; the drain is the end point of the current, opposite to the source. In N-channel MOSFET, the drain is connected to a high potential, such as the positive pole of the power supply or one end of the load; in P-channel MOSFET, the drain is connected to a low potential. The current flows between the source and the drain, through the channel region of the MOSFET; the gate is not directly connected to the source or drain, but is separated from the channel region by an insulating metal oxide layer. The function of the gate is to control the conductivity of the channel region, thereby affecting the current between the source and the drain. By changing the voltage between the gate and the source, the electron concentration (in N-channel MOSFET) or hole concentration (in P-channel MOSFET) in the channel region can be increased or decreased, thereby affecting the conduction state of the MOSFET.
[0055] Optional, such as Figure 4 As shown, the BATFET unit is mainly composed of two PMOS (P-channel enhancement MOSFET) and one NMOS (N-channel enhancement MOSFET). Among them, NMOS (Q1) acts as an inverter to control the on and off states of the two PMOS (the first PMOS element Q2 and the second PMOS element Q3); the BATDRV signal is sent by the charging unit BQ25770 to control the on and off of the BATFET unit. This signal is directly connected to the gate of NMOS (Q1). When the BATDRV signal is high, NMOS Q1 is turned on; conversely, when the BATDRV signal is low, NMOS Q1 is turned off; when the BATDRV signal is high and NMOS Q1 is turned on, it will pull down the potential of the gates of the two PMOS (Q2 and Q3), causing Q2 and Q3 to turn on. The sources of Q2 and Q3 are connected together as part of the switching circuit. When they are turned on, the VBAT voltage of the battery pack unit (Battery) can be connected to the VSYS circuit, thereby realizing the battery powering the system, or the system charging the battery pack unit through BQ25770.
[0056] In addition, when the BATDRV signal is low, Q1 is turned off, and it no longer pulls down the gate potential of Q2 and Q3. At this time, Q2 and Q3 are both in the off state. Even if the battery pack unit is in place, the battery pack unit is disconnected from the VSYS circuit, that is, the battery pack unit can neither supply power to the system nor receive charging current from the system; it should also be noted that when both Q2 and Q3 are turned off, since the two PMOS sources are connected, the body diode (that is, the diode inside the PMOS) will prevent leakage between the battery pack unit (VBAT) and VSYS, ensuring that when the BATFET is turned off, the battery pack unit is completely isolated from the system circuit to avoid energy loss or incorrect power supply.
[0057] Through the above-mentioned implementation of the present application, the circuit principle of the control unit is specifically explained, that is, how to realize the on-off of the battery pack and the system circuit. Through the NMOS and PMOS elements in the control unit, the rapid switching between the battery unit and the system power supply can be realized, ensuring that the battery can be immediately connected to power the system when needed, and when the battery is fully charged or an abnormality occurs, it can be disconnected in time to prevent battery damage caused by overcharging or over-discharging, thereby improving the accuracy and efficiency of battery management; and through the optimization of circuit design, the maintenance and replacement of the battery pack unit becomes easier. The design of the control unit reduces the complexity of the overall BBU unit, and the battery pack is replaced only when necessary, avoiding the high cost and complex process of the overall replacement of the traditional BBU, reducing maintenance costs, and improving maintenance efficiency.
[0058] In an optional embodiment, a battery pack detection unit is further included between the charging unit and the battery pack unit, and after the first loop is formed in series by connecting the power supply module, the battery backup module, and the power module in the storage server, it includes:
[0059] S1, when the battery pack detection unit detects that the battery pack unit is offline, in the battery pack detection unit, turning on the MOSFET switch on the battery detection pin to obtain a first reference circuit; sending first prompt information to the charging unit through the first reference circuit, wherein the first prompt information is used to indicate the offline state of the battery pack;
[0060] S2, when the battery pack detection unit detects that the battery pack unit is online, in the battery pack detection unit, the MOSFET switch on the battery detection pin is disconnected to obtain a second reference circuit; and a second prompt information is sent to the charging unit through the second reference circuit, wherein the first prompt information is used to indicate the online status of the battery pack.
[0061] In the above process S1, when the battery pack detection unit detects that the battery pack unit is offline, in the battery pack detection unit, the MOSFET switch on the battery detection pin is turned on to obtain a first reference circuit; and first prompt information is sent to the charging unit through the first reference circuit, wherein the first prompt information is used to indicate the offline state of the battery pack;
[0062] Specifically, the battery is firstly detected in place. When the battery is correctly inserted into the BBU, the CELLBATPRES pin on the battery pack detection unit is pulled up to a certain level through the internal circuit and resistor of the battery pack unit, indicating that the battery is in place and correctly connected.
[0063] The specific detection principle is as follows Figure 5 As shown, CELL_BATPRES is used as a battery detection pin. When its level is high, it indicates that the battery pack unit is in place, and when its level is low, it indicates that the battery pack unit is pulled out. REGN is the voltage output by the internal LDO of BQ25770, BAT_ID is the battery signal, and BAT_ID is grounded inside the battery; R2 and R3 are voltage divider resistors used to provide a signal start to CELL_BATPRES; Q4 is an NMOS, which acts as a switch; R4 and R5 are gate voltage divider resistors of Q4. When BAT_ID is not connected (i.e., there is no battery pack unit), R4 and R5 make Q4 conductive through voltage division, CELL_BATPRES is grounded, and BQ25770 is notified that there is no battery connected at this time; when the battery pack unit is connected, BAT_ID pulls the gate of Q4 down to ground, and Q4 is turned off. At this time, CELL_BATPRES is pulled up by the voltage division of R2 and R3, and BQ25770 detects the battery pack unit.
[0064] Further when the battery is unplugged, as Figure 6 The MOSFET on the CELL_BATPRES pin shown in the figure is turned on, so that the CELL_BATPRES pin is directly connected to the ground (GND), causing the CELL_BATPRES level to drop to low. After the BQ25770 detects the low-level state of the CELL_BATPRES pin, it immediately turns off the BATFET unit and cuts off the connection between the battery and the system power supply to prevent the battery from interfering with or damaging the system during the removal process. The BQ25770 sends a battery removal interrupt signal to the system (BMC) by pulling down the PROCHOT_N signal. This signal lasts for a period of time to ensure that the BMC can receive the information of battery removal.
[0065] In the above process S2, when the battery pack detection unit detects that the battery pack unit is online, in the battery pack detection unit, the MOSFET switch on the battery detection pin is disconnected to obtain a second reference circuit; and a second prompt information is sent to the charging unit through the second reference circuit, wherein the first prompt information is used to indicate the online status of the battery pack.
[0066] Specifically, when the battery is not in place, the CELL_BATPRES pin is low, and the BQ25770 turns off the BATFET. At this time, when the battery is reinserted into the BBU, the MOSFET on the CELL_BATPRES pin is turned off, and CELL_BATPRES is pulled up to a high level, indicating that the battery is in place again. After detecting the high level of CELL_BATPRES, the BQ25770 obtains the voltage, current, battery type and other information of the battery pack unit within a certain delay. And judge whether the BATFET needs to be turned on based on whether the charging process needs to be carried out.
[0067] The above process is described in a complete implementation method. During normal operation of the server, the CELL_BATPRES pin is at a high level, indicating that the battery is in place. Figure 6 As shown, when the battery is pulled out, the MOSFET on CELL_BATPRES is turned on, grounding the pin. Regardless of whether it is in the charging process at this time, BQ25770 will turn off BATFET and pull down PROCHOT_N for a period of time to notify the BMC of the battery removal behavior, and generate corresponding codes in the internal register. At this time, the PSU still supplies power to the system normally. The BMC can request BQ25770 register information through CHG_SMBus and determine the current state of BATFET.
[0068] When the battery is not in place, the CELL_BATPRES pin is low, and the BQ25770 turns off the BATFET. At this time, when the battery is inserted, the MOSFET on CELL_BATPRES is turned off, and CELL_BATPRES is pulled high. The BQ25770 obtains the battery pack unit information after a certain delay, and determines whether to turn on the BATFET based on whether the charging process is required. This enables the server to respond to changes in battery status in a timely manner during battery hot swapping, protecting the battery and system from damage, and quickly switching power to maintain stable operation of the server. By integrating the detection and control logic in the BQ25770 charging unit, it not only simplifies the circuit design, but also improves the reliability and maintenance efficiency of the system.
[0069] In an optional embodiment, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit to charge the battery pack through the power module, including:
[0070] S1, when the current power of the battery pack unit is lower than the recharging threshold, determining that the current state of the battery pack unit meets the first state condition;
[0071] S2, sending a first control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the first control signal is used to control the NMOS element to be turned on;
[0072] S3, when the NMOS element is turned on, according to the electrical connection relationship among the NMOS element, the first PMOS element and the second PMOS element, it is determined that the battery unit is connected to the first loop.
[0073] S1-S2 is described in a complete implementation:
[0074] First, after the PSU is connected to the mains, it outputs a 12V constant voltage power supply PSU_12V. On the one hand, PSU_12V directly supplies power to the motherboard; on the other hand, PSU_12V is used as the input of the charging unit BQ25770. When it rises above a certain threshold, BQ25770 starts the internal LDO, which will pull CHRG_OK high and enter the charging process. In addition to connecting to the PSU to complete the power-on, BQ25770 can also be powered directly by the battery. When the battery is in place (that is, the CELL_BATPRES voltage is not 0) and the battery pack unit voltage is higher than the startup threshold, BQ25770 will turn on the BATFET and connect the battery to the system. The above thresholds can be dynamically set according to system requirements, and no specific restrictions are made here.
[0075] Furthermore, when the power-on process is completed, if the voltage of the battery presence detection pin CELL_BATPRES is not 0, CHRG_OK is high, and the battery pack unit power is lower than the recharge threshold, the above-mentioned charging unit such as BQ25770 will turn on the BATFET. Specifically, Figure 4 The NMOS element (Q1) shown in the figure is turned on, and then the first PMOS element and the second PMOS element (corresponding to Q2 and Q3) are turned on, and the battery pack unit (ie Figure 4 The VBAT of the Battery in the circuit is connected to the VSYS circuit to supply power to the system or charge the battery pack unit by BQ25770.
[0076] Through the above implementation methods recorded in the present application, when the current power of the battery pack unit is lower than the recharging threshold, it is determined that the current state of the battery pack unit meets the first state condition; through the electrical connection between the charging unit and the third gate of the NMOS element, a first control signal is sent to the NMOS element; when the NMOS element is turned on, according to the electrical connection relationship between the NMOS element, the first PMOS element and the second PMOS element, it is determined that the battery pack unit is connected to the first loop, and the connection and disconnection of the battery pack unit can be accurately controlled. When the NMOS element receives the first control signal and turns on, the first PMOS element and the second PMOS element will be turned on to form a low impedance path, allowing a large current to pass through, charging the battery pack unit, and improving the charging efficiency and safety of the battery.
[0077] In an optional implementation, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, including:
[0078] S1, when the charging current of the battery pack unit is lower than the charging termination threshold and the charging voltage is higher than the recharging threshold, determining that the current state of the battery pack unit meets the second state condition;
[0079] S2, sending a second control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the second control signal is used to control the NMOS element to turn off;
[0080] S3, when the NMOS element is turned off, determining that the battery unit is disconnected from the first loop according to the electrical connection relationship between the first source of the first PMOS element and the second source of the second PMOS element.
[0081] S1-S3 are described in a complete implementation method: when the charging current is lower than the termination threshold and the charging voltage is higher than the recharge threshold, the charging is determined to be complete, the charging process is terminated, and CHRG_OK is pulled low to notify the BMC that the charging is complete. When the server is in a high power consumption state, the BMC can actively turn off the BATFET through CHG_SMBus. Specifically, Figure 4 The NMOS element (Q1 unit) is turned off, and the first PMOS element and the second PMOS element (ie, Q2 and Q3) are not turned on to stop charging the battery pack unit until the power consumption of the server is reduced and then the charging process is performed to maintain the server performance.
[0082] Through the above implementation, when the charging current of the battery pack unit is lower than the charging termination threshold and the charging voltage is higher than the recharging threshold, it is determined that the current state of the battery pack unit meets the second state condition; through the electrical connection between the charging unit and the third gate of the NMOS element, a second control signal is sent to the NMOS element; when the NMOS element is turned off, according to the electrical connection relationship between the first source of the first PMOS element and the second source of the second PMOS element, it is determined that the battery pack unit is disconnected from the first circuit, thereby realizing cutting off the charging of the battery in a safe fully charged state, ensuring that the battery will not be overcharged, avoiding problems such as battery cell bulging and shortened life, reducing the thermal stress of the battery and the number of charge and discharge cycles, and improving the safety of battery use.
[0083] In an optional embodiment, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, including at least one of the following:
[0084] Method 1: Under a target risk scenario, the current power of the battery pack unit is obtained, wherein the target risk scenario is to determine, according to a deep learning algorithm, that the power supply operation performed by the power module satisfies an abnormal execution condition; when the current power does not reach a target power threshold, a first circuit is formed in response to a first charging instruction, wherein the target power threshold is a full power value of the battery pack unit, and the first charging instruction is used to instruct a control unit in the battery backup module to obtain the first circuit according to an electrical connection relationship between an NMOS element, a first PMOS element, and a second PMOS element; and the battery pack unit is charged through the power module;
[0085] Method 2: When it is monitored that the battery pack unit only performs discharge operations within the target time period, and the battery pack unit has a power value lower than a reference power threshold within the target monitoring time period, a first circuit is formed according to a second charging instruction, wherein the reference power threshold is determined according to a historical charging power value of the battery pack unit, and the second charging instruction is a target signal instruction transmitted by the BMC unit through a target communication link using a target communication protocol, the target communication protocol is a signal transmission protocol between the BMC unit and the control unit, and the target signal instruction is used to instruct the control unit to control the NMOS element to conduct to form the first circuit; and the battery pack unit is charged through the power module.
[0086] In the above-mentioned embodiment 1, the above-mentioned risk scenario can specifically be a power supply unit PSU failure scenario, and the power module is determined to perform power supply operations according to the deep learning algorithm to meet the abnormal execution conditions, including but not limited to predicting the input voltage, output voltage, output current, temperature, fault frequency, operating time and other characteristics related to the PSU state through the deep learning algorithm, and setting a failure risk threshold according to the operating environment and application requirements of the PSU. When the failure risk of the PSU exceeds this threshold, it is determined that the abnormal execution conditions are met, and the system considers that the PSU has entered a failure state. The above-mentioned target threshold can be set dynamically.
[0087] In another embodiment, during the normal operation of the server, the battery unit is used as a backup power source and is usually in a discharged state. In particular, when the server is under high load operation, the battery unit may need to provide additional power support. Long-term discharge will cause the battery unit to consume power. If the power is too low, it may not be enough to maintain the operation of the server and protect data security when the PSU (power supply unit) suddenly fails. In order to avoid this situation, it is necessary for the system to automatically identify and start the charging process when the battery power is below a certain threshold to ensure that the battery power is sufficient.
[0088] Specifically, the BMC continuously monitors the voltage of the battery cell. This information is obtained from the BQ25770 charging control unit through the CHG_SMBus communication link. The BMC communicates with the BQ25770 charging unit through CHG_SMBus, and can read the battery power, battery temperature, charging current, charging status and other information in the BQ25770 internal register. It can also adjust the charging parameters, or externally control the BATFET to control whether to charge the battery pack unit. When the BMC detects that the battery voltage drops below the threshold set by the user (i.e., the above-mentioned reference power threshold), the system determines that the battery is in a low power state; once the low power state of the battery is identified, the BMC sends a control instruction to the BQ25770 through CHG_SMBus, requiring the BATFET to be turned on, thereby connecting the power supply of the PSU to the battery charging path to form the above-mentioned first circuit and start the charging process. In this process, the BQ25770 will charge the battery according to the preset charging strategy (such as charging current, charging power, etc.) until the battery power returns to a safe level.
[0089] The above implementation can set whether the BQ25770 enables the autonomous charging management function through a register. If this function is enabled, when the PSU unit is working normally, when the battery pack unit drops in power due to self-discharge and exceeds the recharge threshold, a new charging process is automatically started, and the charging termination conditions are the same as the normal charging process. This process is autonomously controlled by the BQ25770 unit, and autonomous charging management can be completed as long as the PSU_12V output by the PSU unit is normally input.
[0090] Specifically, the autonomous charging management can be controlled by the system, and the built-in autonomous charging management function of BQ25770 can be disabled in the register of BQ25770, so that the server can control the on and off of BATFET to control the charging process based on parameters such as PSU normal operation time, PSU failure frequency, and current battery pack unit power, with the assistance of deep learning algorithms, by communicating with BQ25770 through CHG_SMBus. The specific implementation is as follows:
[0091] Method 1: When the server believes that the PSU has a risk of failure in the near future based on the conclusion output by the deep learning algorithm, the BMC reads the current power of the battery pack unit. If the current power is not full, it controls BQ25770 through CHG_SMBus to turn on the BATFET unit to start the charging process;
[0092] Method 2: When the battery power is lower than a certain threshold (the threshold can be set by the user) during long-term discharge, the charging process is automatically started. For example: the user sets the threshold to 11.5V, then when the battery voltage drops below 11.5V, the BMC unit controls the BQ25770 through CHG_SMBus to turn on the BATFET unit to start the charging process.
[0093] It should also be noted that method one and method two can be used in combination. For example, the weight value of the charging condition for method one and the weight value of the charging condition for method two can be preset, and the conditions of both method one and method two can be comprehensively considered to determine whether to start charging or other battery management processes.
[0094] The adaptive charging management of the above-mentioned battery cells can reduce system failures caused by low battery power, improve the stability and reliability of the entire server system, and allow users to set low-battery thresholds according to specific needs and scenarios, thereby enhancing the flexibility and applicability of charging strategies, further reducing the charging frequency of battery pack units, and further improving the service life of battery pack units.
[0095] As an optional implementation, the BATFET circuit can also be optimized, that is, the BATFET circuit can be modified, Q2 can be removed, and VSYS can be connected to the source of Q3. This allows the server to draw part of the power from the battery in a high power consumption state, relieve the pressure on the PSU unit, and maintain the stability of the power input. The specific design circuit is as follows Figure 7 shown.
[0096] In this application, a power-off protection function, namely, the BBU discharge process, is also designed. When the server is in normal operation, the PSU unit is used for power supply. When the PSU unit cannot supply power due to a fault or other reasons, the BQ25770 detects the PSU_12V voltage to confirm that it has entered the power-off protection process. At this time, the BQ25770 turns on the BATFET, and at the same time, the BQ25770 will generate a corresponding error code in the internal register, and the BMC can read the relevant content through CHG_SMBus. After entering the power-off protection, the battery pack unit continues to supply power to the system to maintain the data. The BMC can determine whether the PSU power-off behavior exists through PSU_I2C. If not, the BATFET is turned off through CHG_SMBus to prevent the battery pack from charging through the system loop on the motherboard. If so, the error code is checked through CHG_SMBus to monitor the battery power in real time to determine the remaining protection time.
[0097] It should also be noted that the implementation method described in this application can be used for hot-swapping of any battery that requires off-chip controlled power-off protection circuits. The charging circuit shown in this application achieves higher charging power and power supply power through a parallel scheme, and can also be connected in series on the circuit from the PSU to the motherboard according to actual design requirements, without specific restrictions here; through the design of the charging unit on the BBU by this application, a BATFET unit for controlling the on-off between the battery and the system power supply is added, the circuit is streamlined, and a safe, highly compatible, and easy-to-maintain BBU battery pack hot-swap function is achieved.
[0098] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.
[0099] According to another aspect of the embodiments of the present application, a battery power supply device for implementing the above-mentioned battery power supply method is also provided. Figure 8 As shown, the device comprises:
[0100] A first determining unit 802 forms a first loop by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server;
[0101] The first power supply unit 804, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, controls the battery pack unit to be connected to the first loop through the control unit in the battery backup module to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first loop and a second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series;
[0102] The second power supply unit 806, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, controls the battery pack unit to disconnect from the first circuit through the control unit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through the third circuit when the power module is offline, and the third circuit is formed by the battery pack unit, the charging unit, the power module and the control unit connected in series.
[0103] Optionally, the power supply device of the above-mentioned battery includes a connection module, and the control unit includes an NMOS element, a first PMOS element and a second PMOS element, the first drain of the first PMOS element is connected to the first circuit, the first source of the first PMOS element is electrically connected to the second source of the second PMOS element, the second drain of the second PMOS element is electrically connected to the battery pack unit, the first gate of the first PMOS element, the second gate of the second PMOS element and the third drain of the NMOS element are electrically connected, the third gate of the NMOS element is electrically connected to the charging unit, and the third source of the NMOS element is electrically connected to the battery pack unit.
[0104] Optionally, the above-mentioned first determination unit 802 is also used to: when the battery pack detection unit detects that the battery pack unit is offline, in the battery pack detection unit, turn on the MOSFET switch on the battery detection pin to obtain a first reference circuit; send a first prompt information to the charging unit through the first reference circuit, wherein the first prompt information is used to indicate the offline state of the battery pack; when the battery pack detection unit detects that the battery pack unit is online, in the battery pack detection unit, turn off the MOSFET switch on the battery detection pin to obtain a second reference circuit; send a second prompt information to the charging unit through the second reference circuit, wherein the first prompt information is used to indicate the online state of the battery pack.
[0105] Optionally, the first power supply unit 804 is also used to: when the current power of the battery pack unit is lower than the recharging threshold, determine that the current state of the battery pack unit satisfies the first state condition; send a first control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the first control signal is used to control the conduction of the NMOS element; when the NMOS element is conducted, determine that the battery pack unit is connected to the first loop according to the electrical connection relationship between the NMOS element, the first PMOS element and the second PMOS element.
[0106] Optionally, the second power supply unit 806 is also used to: determine that the current state of the battery pack unit satisfies the second state condition when the charging current of the battery pack unit is lower than the charging termination threshold and the charging voltage is higher than the recharging threshold; send a second control signal to the NMOS element through the electrical connection between the charging unit and the third gate of the NMOS element, wherein the second control signal is used to control the NMOS element to shut down; and determine that the battery pack unit is disconnected from the first loop based on the electrical connection relationship between the first source of the first PMOS element and the second source of the second PMOS element when the NMOS element is turned off.
[0107] Optionally, the first power supply unit 804 further includes a switching module, which is used to obtain the current power of the battery pack unit under a target risk scenario, wherein the target risk scenario is to determine, according to a deep learning algorithm, that the power supply module performs a power supply operation that satisfies an abnormal execution condition; when the current power does not reach a target power threshold, a first circuit is formed in response to a first charging instruction, wherein the target power threshold is a full power value of the battery pack unit, and the first charging instruction is used to instruct the control unit in the battery backup module to obtain the first circuit according to the electrical connection relationship between the NMOS element, the first PMOS element, and the second PMOS element; the battery pack unit is charged through the power module; when it is monitored that the battery pack unit only performs a discharge operation within a target time period, and the battery pack unit has a power value lower than a reference power threshold within a target monitoring time period, a first circuit is formed according to a second charging instruction, wherein the reference power threshold is determined according to a historical charging power value of the battery pack unit, the second charging instruction is a target signal instruction transmitted by the BMC unit through a target communication link using a target communication protocol, the target communication protocol is a signal transmission protocol between the BMC unit and the control unit, and the target signal instruction is used to instruct the control unit to control the NMOS element to conduct to form the first circuit; the battery pack unit is charged through the power module.
[0108] According to another aspect of the embodiment of the present application, an electronic device for implementing the power supply method of the battery in the memory is also provided. The electronic device may be Figure 1 The terminal device or server shown in the figure. This embodiment is described by taking the electronic device as a mobile phone or a computer as an example. Fig. 9 As shown, the electronic device includes a memory 902 and a processor 904. The memory 902 stores a computer program, and the processor 904 is configured to execute the steps in any of the above method embodiments through the computer program.
[0109] Optionally, in this embodiment, the electronic device may be located in at least one network device among a plurality of network devices of a computer network.
[0110] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0111] S1, a first loop is formed by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server;
[0112] S2, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first loop and a second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series;
[0113] S3, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through the third circuit when the power module is offline, and the third circuit is formed by the battery pack unit, the charging unit, the power module and the control unit connected in series.
[0114] Alternatively, a person skilled in the art may understand that: Fig. 9 The structure shown is for illustration only, and the electronic device may also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (Mobile Internet Devices, MID), a PAD, or other terminal devices. Fig. 9 The structure of the electronic device is not limited. Fig. 9 More or fewer components (such as network interfaces, etc.) as shown in, or with Fig. 9 Different configurations are shown.
[0115] Among them, the memory 902 can be used to store software programs and modules, such as the program instructions / modules corresponding to the battery power supply method and device in the embodiments of the present application. The processor 904 executes various functional applications by running the software programs and modules stored in the memory 902, that is, realizing the above-mentioned battery power supply method. The memory 902 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 902 may further include a memory remotely located relative to the processor 904, and these remote memories may be connected to the terminal via a network. Examples of the above-mentioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof. Among them, the memory 902 can be specifically, but not limited to, used to store information such as page elements and page styles. As an example, such as Fig. 9As shown, the memory 902 may include but is not limited to the first determining unit 802, the first power supply unit 804 and the second power supply unit 806 in the battery power supply device. In addition, it may also include but is not limited to other module units in the battery power supply device, which will not be repeated in this example.
[0116] Optionally, the transmission device 906 is used to receive or send data via a network. Specific examples of the above-mentioned network may include a wired network and a wireless network. In one example, the transmission device 906 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices and routers via a network cable so as to communicate with the Internet or a local area network. In one example, the transmission device 906 is a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0117] In addition, the electronic device further includes: a display 908; and a connection bus 910, which is used to connect various module components in the electronic device.
[0118] In other embodiments, the terminal device or server may be a node in a distributed system, wherein the distributed system may be a blockchain system, and the blockchain system may be a distributed system formed by connecting the multiple nodes through network communication. The nodes may form a point-to-point network, and any form of computing device, such as a server, terminal or other electronic device, may become a node in the blockchain system by joining the point-to-point network.
[0119] According to one aspect of the present application, a computer-readable storage medium is provided, and a processor of a computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the method provided in the above various optional implementations;
[0120] Optionally, in this embodiment, the computer-readable storage medium may be configured to store a computer program for performing the following steps:
[0121] S1, a first loop is formed by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server;
[0122] S2, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes a first loop and a second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series;
[0123] S3, in response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, wherein the battery pack unit is used to supply power to the power module through the third circuit when the power module is offline, and the third circuit is formed by the battery pack unit, the charging unit, the power module and the control unit connected in series.
[0124] Optionally, in the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program that has a predetermined function, and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories), or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be part of an overall module or unit that includes the function of the module or unit.
[0125] Optionally, in this embodiment, a person of ordinary skill in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing hardware related to the terminal device through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.
[0126] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which can be personal computers, servers or network devices, etc.) to execute all or part of the steps of the methods of each embodiment of the present application.
[0127] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0128] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic, for example, the division of units is only a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0129] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0130] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0131] The above are only preferred implementations of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
[0132] It should be noted that the above modules can be implemented by software or hardware. For the latter, it can be implemented in the following ways, but not limited to: the above modules are all located in the same processor; or the above modules are located in different processors in any combination.
[0133] An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when running.
[0134] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media that can store computer programs, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk.
[0135] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0136] In an exemplary embodiment, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0137] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.
[0138] An embodiment of the present application further provides another computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.
[0139] The embodiments of the present application also provide a computer program, which includes computer instructions, which are stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the steps in any one of the above method embodiments.
[0140] For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary implementation modes, and this embodiment will not be described in detail herein.
[0141] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
[0142] The above are only preferred embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the principles of the present application shall be included in the protection scope of the present application.
Claims
1. A battery power supply method, characterized in that: include: A first loop is formed by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server; In response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes the first loop and the second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series; In response to the charging unit detecting that the current state of the battery pack unit satisfies the second state condition, the control unit controls the battery pack unit to disconnect from the first circuit to form a second circuit, wherein the battery pack unit is used to supply power to the power consumption module through a third circuit when the power supply module is offline, and the third circuit is formed by connecting the battery pack unit, the charging unit, the power consumption module and the control unit in series.
2. The method according to claim 1, characterized in that The control unit includes an NMOS element, a first PMOS element and a second PMOS element, the first drain of the first PMOS element is connected to the first loop, the first source of the first PMOS element is electrically connected to the second source of the second PMOS element, the second drain of the second PMOS element is electrically connected to the battery pack unit, the first gate of the first PMOS element, the second gate of the second PMOS element and the third drain of the N MOS element are electrically connected, the third gate of the N MOS element is electrically connected to the charging unit, and the third source of the N MOS element is electrically connected to the battery pack unit.
3. The method according to claim 2, characterized in that A battery pack detection unit is also included between the charging unit and the battery pack unit. After the power module, the battery backup module, and the power module in the storage server are connected in series to form a first loop, the method includes: In the case where the battery pack detection unit detects that the battery pack unit is offline, in the battery pack detection unit, a MOSFET switch on a battery detection pin is turned on to obtain a first reference circuit; and first prompt information is sent to the charging unit through the first reference circuit, wherein the first prompt information is used to indicate the offline state of the battery pack; In the case where the battery pack detection unit detects that the battery pack unit is online, in the battery pack detection unit, the MOSFET switch on the battery detection pin is disconnected to obtain a second reference circuit; and a second prompt information is sent to the charging unit through the second reference circuit, wherein the first prompt information is used to indicate the online status of the battery pack.
4. The method according to claim 2, characterized in that: In response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, including: In a case where the current power level of the battery unit is lower than a recharging threshold, determining that the current state of the battery unit satisfies the first state condition; Sending a first control signal to the N MOS element through the electrical connection between the charging unit and the third gate of the N MOS element, wherein the first control signal is used to control the N MOS element to be turned on; When the N MOS element is turned on, the battery unit is determined to be connected to the first loop according to the electrical connection relationship between the N MOS element, the first PMOS element and the second PMOS element.
5. The method according to claim 2, characterized in that: In response to the charging unit detecting that the current state of the battery pack unit meets the second state condition, the control unit controls the battery pack unit to disconnect from the first loop to form a second circuit, including: When the charging current of the battery pack unit is lower than the charging termination threshold and the charging voltage is higher than the recharging threshold, determining that the current state of the battery pack unit satisfies the second state condition; Sending a second control signal to the N MOS element through the electrical connection between the charging unit and the third gate of the N MOS element, wherein the second control signal is used to control the N MOS element to turn off; When the NMOS element is turned off, the battery unit is determined to be disconnected from the first loop according to the electrical connection relationship between the first source of the first PMOS element and the second source of the second PMOS element.
6. The method according to claim 2, characterized in that In response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, the control unit in the battery backup module controls the battery pack unit to be connected to the first loop to form a first circuit, so as to charge the battery pack through the power module, including at least one of the following: In a target risk scenario, the current power of the battery pack unit is obtained, wherein the target risk scenario is to determine, according to a deep learning algorithm, that the power supply module performs a power supply operation that satisfies an abnormal execution condition; when the current power does not reach a target power threshold, the first circuit is formed in response to a first charging instruction, wherein the target power threshold is a full power value of the battery pack unit, and the first charging instruction is used to instruct the control unit in the battery backup module to obtain the first circuit according to the electrical connection relationship between the N MOS element, the first PMOS element, and the second PMOS element; and the battery pack unit is charged through the power module; When it is monitored that the battery pack unit only performs a discharge operation within a target time period, and the battery pack unit has a power value lower than a reference power threshold within the target monitoring time period, the first circuit is formed according to a second charging instruction, wherein the reference power threshold is determined according to a historical charging power value of the battery pack unit, the second charging instruction is a target signal instruction transmitted by the BMC unit through a target communication link using a target communication protocol, the target communication protocol is a signal transmission protocol between the BMC unit and the control unit, and the target signal instruction is used to instruct the control unit to control the N MOS element to conduct to form the first circuit; and the battery pack unit is charged through the power module.
7. A battery power supply device, characterized in that: include: A first determining unit, which forms a first loop by connecting a power module, a battery backup module, and a power module in a storage server in series, wherein the first loop is used to supply power to the storage server; A first power supply unit, in response to the charging unit in the battery backup module detecting that the current state of the battery pack unit meets the first state condition, controls the battery pack unit to be connected to the first loop through the control unit in the battery backup module to form a first circuit, so as to charge the battery pack through the power module, wherein the first circuit includes the first loop and the second loop, and the second loop is formed by the charging unit in the battery backup module, the control unit and the battery pack unit connected in series; A second power supply unit, in response to the charging unit detecting that the current state of the battery pack unit satisfies a second state condition, controls the battery pack unit to disconnect from the first circuit through the control unit to form a second circuit, wherein the battery pack unit is used to supply power to the power consumption module through a third circuit when the power supply module is offline, and the third circuit is formed by connecting the battery pack unit, the charging unit, the power consumption module and the control unit in series.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, wherein the computer program implements the steps of the method described in any one of claims 1 to 6 when executed by a processor.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method described in any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method described in any one of claims 1 to 6 are implemented.