Software upgrading method and device, equipment and storage medium

By determining the version type of energy storage equipment and setting the target interaction method, the problems of cumbersome software upgrade steps and low accuracy in the existing technology are solved, and an efficient software upgrade process is achieved.

CN119987809APending Publication Date: 2025-05-13ZHEJIANG LEAPENERGY TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411996641.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

When the prior art upgrades software in different versions of energy storage equipment, the steps are cumbersome and the accuracy is low, resulting in low software upgrade efficiency.

Method used

By determining the version type of the energy storage device to be upgraded, the target interaction mode of each chip is determined based on the version type, so as to receive the software upgrade protocol sent by the preset device. The interaction mode of each chip is one of an internal channel, an external channel, or an internal-external channel.

Benefits of technology

It realizes software upgrades using the general software upgrade protocol for energy storage equipment of different versions, improving the efficiency of software upgrades.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119987809A_ABST
    Figure CN119987809A_ABST
Patent Text Reader

Abstract

The invention discloses a software upgrading method and device, equipment and a storage medium. The software upgrading method is applied to a to-be-upgraded energy storage device. The software upgrading method comprises the following steps: determining a version type of the to-be-upgraded energy storage device; based on the version type of the to-be-upgraded energy storage device, determining a target interaction mode of each chip in the to-be-upgraded energy storage device so as to receive a software upgrading protocol sent by a preset device by using the target interaction mode, the interaction mode of each chip being one of internal channel interaction, external channel interaction and internal-external channel interaction. According to the scheme, the software upgrading efficiency of the to-be-upgraded energy storage equipment can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a software upgrading method, device, equipment and storage medium. Background Art

[0002] There are different versions of existing energy storage devices, and each version type of energy storage device corresponds to a set of software. From the beginning of production, it is necessary to pay attention to whether the software of the energy storage device is compatible with the corresponding version type. When the energy storage device is upgraded, the software corresponding to the energy storage device needs to be upgraded synchronously. However, when the same functional requirement needs to be added to energy storage devices of different versions, it is necessary to manually test the changes of multiple software at the same time. Manually judge and identify the version type of the energy storage device and flash the program for the software of different versions. However, this kind of manual judgment of the version type of the energy storage device and flashing the program for the software of different versions will result in cumbersome steps and low accuracy in the software upgrade process. As a result, the software upgrade efficiency is low during the entire software upgrade process.

[0003] In view of the existing technical defects, how to provide a solution that can improve the software upgrade efficiency of energy storage equipment is a technical problem that needs to be solved urgently by technical personnel in this field. Summary of the invention

[0004] The present application at least provides a software upgrade method, apparatus, device and storage medium.

[0005] The present application provides a software upgrade method, which is applied to an energy storage device to be upgraded. The software upgrade method includes: determining a version type of the energy storage device to be upgraded; based on the version type of the energy storage device to be upgraded, determining a target interaction mode of each chip in the energy storage device to be upgraded so as to receive a software upgrade protocol sent by a preset device using the target interaction mode, wherein the interaction mode of each chip is one of internal channel interaction, external channel interaction, and internal-external channel interaction.

[0006] In some embodiments, based on the version type of the energy storage device to be upgraded, the target interaction mode of each chip in the energy storage device to be upgraded is determined, including: determining whether there is a target chip among the chips, and the target interaction mode of the target chip is inconsistent with the current interaction mode of the chip; adjusting the current interaction mode of the target chip to the target interaction mode.

[0007] In some embodiments, the version type is one of the first version, the second version, and the third version, wherein the first chip and the second chip in the energy storage device to be upgraded in the first version are in a working state, the first chip in the energy storage device to be upgraded in the second version is in a working state, and the first chip and the third chip in the energy storage device to be upgraded in the third version are in a working state, and the current interaction mode of the target chip is adjusted to the target interaction mode, including: in response to the version type being the first version, setting the first chip as an external channel and the second chip as an internal channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device; or, in response to the version type being the second version, setting the first chip as an external channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device; or; in response to the version type being the third version, setting the first chip as an internal channel and the third chip as an external channel so as to use the third chip in the external channel to receive the software upgrade protocol sent by the preset device.

[0008] In some embodiments, determining the version type of the energy storage device to be upgraded includes: determining whether the energy storage device to be upgraded has an address self-allocation function, the address self-allocation function is used to perform an identification allocation work to the second chip; in response to the energy storage device to be upgraded having the address self-allocation function, determining the version type of the energy storage device to be upgraded to be the first version.

[0009] In some embodiments, the software upgrade method further includes: in response to the energy storage device to be upgraded not having an address self-allocation function, determining whether the energy storage device to be upgraded has master-slave communication; in response to the energy storage device to be upgraded not having master-slave communication, determining the version type of the energy storage device to be upgraded as the second version; or, in response to the energy storage device to be upgraded having master-slave communication, determining the version type of the energy storage device to be upgraded as the third version.

[0010] In some embodiments, the energy storage device to be upgraded in the first version includes multiple second chips. In response to the version type being the first version, the first chip is set to an external channel and the second chip is set to an internal channel, including: in response to the version type being the first version, self-allocating addresses for each second chip to obtain each allocated second chip; determining the target interaction mode as setting the first chip as an external channel and setting each allocated second chip as an internal channel.

[0011] In some embodiments, the energy storage device to be upgraded in the third version includes multiple third chips. In response to the version type being the third version, the first chip is set to an internal channel and the third chip is set to an external channel, including: in response to the version type being the third version, a cluster address is assigned to each third chip to obtain each assigned third chip; and the target interaction mode is determined as setting the first chip as an internal channel and setting each assigned third chip as an external channel.

[0012] The present application provides a software upgrade device, which is arranged in an energy storage device to be upgraded, and includes: a first determination module and a second determination module; the first determination module is used to determine the version type of the energy storage device to be upgraded; the second determination module is used to determine the target interaction mode of each chip in the energy storage device to be upgraded based on the version type of the energy storage device to be upgraded.

[0013] The present application provides an electronic device, including a memory and a processor, wherein the processor is used to execute program instructions stored in the memory to implement the above-mentioned software upgrade method.

[0014] The present application provides a computer-readable storage medium on which program instructions are stored. When the program instructions are executed by a processor, the above-mentioned software upgrade method is implemented.

[0015] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0016] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present application and are used together with the specification to illustrate the technical solution of the present application.

[0018] Figure 1 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 1 ;

[0019] Figure 2 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 2 ;

[0020] Figure 3 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 3 ;

[0021] Figure 4 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 4 ;

[0022] Figure 5 It is a structural diagram of an embodiment of the software upgrading device of the present application;

[0023] Figure 6 It is a structural schematic diagram of an embodiment of the electronic device of the present application;

[0024] Figure 7 It is a structural diagram of an embodiment of a computer-readable storage medium of the present application. DETAILED DESCRIPTION

[0025] The scheme of the embodiment of the present application is described in detail below in conjunction with the drawings of the specification.

[0026] In the following description, for the purpose of explanation rather than limitation, specific details such as specific system structures, interfaces, and technologies are provided to facilitate a thorough understanding of the present application.

[0027] The term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the objects associated before and after are in an "or" relationship. In addition, "many" in this article means two or more than two. In addition, the term "at least one" in this article means any combination of at least two of any one or more of a plurality of, for example, including at least one of A, B, and C, can mean including any one or more elements selected from the set consisting of A, B, and C.

[0028] The present application provides some software upgrade methods and software upgrade devices. The application scenarios of the software upgrade method include but are not limited to the upgrade of household energy storage equipment. The executor of the software upgrade method may be a software upgrade device. For example, the software upgrade device may be arranged in a terminal device or a server or other processing device, wherein the terminal device may be a device for software upgrade, a user equipment (User Equipment, UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (Personal Digital Assistant, PDA), a handheld device, a computing device, a vehicle-mounted device, etc. In some possible implementations, the software upgrade method may be implemented by a processor calling computer-readable instructions stored in a memory.

[0029] See also Figure 1, Figure 1 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 1 Specifically, the software upgrade method is applied to the energy storage device to be upgraded, and the software upgrade method may include the following steps:

[0030] Step S11: Determine the version type of the energy storage device to be upgraded.

[0031] The energy storage device to be upgraded may be a household energy storage device. Specifically, the household energy storage device may refer to an energy storage system used in a home. The energy storage device to be upgraded includes several chips. At least some of the chips included in the energy storage device to be upgraded are of different types. Each energy storage device to be upgraded is equipped with the same target software. Among them, the target software is applied to energy storage devices to be upgraded of multiple version types. In the process of software upgrade of energy storage devices to be upgraded of different version types, the energy storage devices to be upgraded of different version types may have different relay control logic. It is understandable that the energy storage device to be upgraded may include several relays. Specifically, several relays may include relays in a battery pack, also referred to as relays in a pack, and the relays in the pack are negative relays. Several relays may include relays in a high-voltage box, and the relays in the high-voltage box may be negative relays, positive relays, and pre-charge relays. In some application scenarios, when the energy storage device to be upgraded is in the first version, the several relays include relays in a pack and relays in a high-voltage box. In some application scenarios, when the energy storage device to be upgraded is in the second version or the third version, the plurality of relays include a high-voltage box relay.

[0032] After the above step S11, according to the different version types determined, the control instructions sent to the relay by the target software corresponding to the energy storage devices to be upgraded in different version types may be the same or different. Therefore, the present application may also perform preset processing on the relays of the energy storage devices to be upgraded in different version types, so that the relays in the energy storage devices to be upgraded after the preset processing can receive the control instructions sent by the target software and execute the control functions related to the control instructions.

[0033] When the energy storage device to be upgraded is in a different version type, at least some of the chips are in working state, and data communication is performed between the chips in working state. The chip type may include but is not limited to the type corresponding to the first chip, the type corresponding to the second chip, and the type corresponding to the third chip. Among them, the types of different chips can be determined according to the type of management unit related to the battery. The management unit related to the first chip is the battery system management unit (Battery System Management Unit, BSMU). The management unit related to the second chip is the battery cluster management unit (Battery Cluster Management Unit, BCMU). The management unit related to the third chip is the battery system management unit (Battery Array Management Unit, BAMU). It can be understood that the first chip can be a first chip BCMU. The second chip can be a second chip BSMU. The first chip can be a first chip BAMU.

[0034] The version type of the energy storage device to be upgraded may be any one of the first version, the second version, and the third version. In the process of upgrading the energy storage device to be upgraded, the version type of the energy storage device to be upgraded may be adjusted. In some application scenarios, the energy storage device to be upgraded may be adjusted from the first version to the third version, or from the second version to the third version. In other application scenarios, the energy storage device to be upgraded may be adjusted from the third version to the first version, or from the third version to the second version. In the process of adjusting the version types of the energy storage device to be upgraded, the switching of the working modes of each chip in the energy storage device to be upgraded is involved. It can be understood that when the working mode of any chip is in the working state, the chip can perform normal processing and perform corresponding control operations according to the communication protocol. When the working mode of any chip is in the dormant state, the chip can not be used normally. In addition, when the version type is the first version, the energy storage device to be upgraded can also be referred to as a first-generation machine, also known as an all-in-one product. When the version type is the second version, the energy storage device to be upgraded can also be referred to as a second-generation machine, also known as a second-generation product. When the version type is the third version, the energy storage device to be upgraded can also be called a third-generation machine, also known as a parallel project.

[0035] When the energy storage device to be upgraded is in different version types, at least some of the chips are in working state. Specifically, when the energy storage device to be upgraded is in the first version, the first chip and the second chip in the energy storage device to be upgraded are in working state. Among them, when the energy storage device to be upgraded is in the first version, the number of first chips in working state in the energy storage device to be upgraded is one, and the number of second chips in working state is at least one. The number of second chips is limited by the working voltage of each component. Exemplarily, when the energy storage device to be upgraded is in the first version, there is one first chip BCMU and the second chip BSMU consists of 1-8. When the energy storage device to be upgraded is the first version, the interaction mode required by the energy storage device to be upgraded is the first target interaction mode. The first target interaction mode includes that the interaction mode of the first chip is internal-external channel interaction, and the interaction mode of the second chip is internal channel interaction. In some application scenarios, when the energy storage device to be upgraded is in the first version, the interaction mode of each chip may refer to the communication mode of the second chip used only for internal communication. The interaction mode of the second chip is internal channel interaction. In other application scenarios, when the energy storage device to be upgraded is in the first version, the interaction mode of each chip may refer to the communication mode of the first chip. The interaction mode of the first chip is internal-external channel interaction. Among them, internal-external channel interaction may mean that the first chip can communicate internally with the second chip, or it may mean that the first chip can communicate externally with a preset device. The preset device may be an inverter. It is understandable that the first chip BCMU is responsible for internal communication with the second chip in the first version, and for external interaction with the PCS (inverter). The second chip BSMU only communicates internally.

[0036] Specifically, when the energy storage device to be upgraded is in the second version, the first chip in the energy storage device to be upgraded is in a working state. Among them, when the energy storage device to be upgraded is in the second version, the number of first chips in a working state in the energy storage device to be upgraded may be at least one. When the energy storage device to be upgraded is the second version, the interaction mode required by the energy storage device to be upgraded is the second target interaction mode. The second target interaction mode includes that the interaction mode of the first chip is external channel interaction. In some application scenarios, when the energy storage device to be upgraded is in the second version, the interaction mode of each chip may refer to the communication mode of the first chip used only for external communication. The interaction mode of the first chip is external channel interaction. External channel interaction may refer to that the first chip only communicates with the preset device. The preset device may be an inverter. It can be understood that the first chip BCMU is responsible for external interaction with the PCS (inverter) in the second version.

[0037] Specifically, when the energy storage device to be upgraded is in the third version, the first chip and the third chip in the energy storage device to be upgraded are in working state. When the energy storage device to be upgraded is the third version, the interaction mode required by the energy storage device to be upgraded is the third target interaction mode. The third target interaction mode includes that the interaction mode of the third chip is internal-external channel interaction, and the interaction mode of the first chip is internal channel interaction. In some application scenarios, when the energy storage device to be upgraded is in the third version, the interaction mode of each chip may refer to the communication mode of the first chip used only for internal communication. The interaction mode of the first chip is internal channel interaction. In other application scenarios, when the energy storage device to be upgraded is in the third version, the interaction mode of each chip may refer to the communication mode of the third chip. The interaction mode of the third chip is internal-external channel interaction. Among them, internal-external channel interaction may mean that the third chip can communicate internally with the first chip, and the third chip can communicate externally with the preset device. The preset device may be an inverter. It can be understood that the third chip BAMU is responsible for internal communication with the first chip in the third version, and external interaction with the PCS (inverter). The first chip BCMU only performs internal communication.

[0038] Under different version types, the energy storage devices to be upgraded use the same target software. When the energy storage devices to be upgraded are upgraded, the target software needs to be upgraded synchronously. The software upgrade of the energy storage devices to be upgraded can be completed by sending the general software upgrade protocol to each chip in the energy storage devices to be upgraded of different version types. That is to say, the upgrade of the target software of the energy storage devices to be upgraded is completed. The upgrade channel setting method of each chip of the energy storage devices to be upgraded of different version types is different. When the energy storage devices to be upgraded of each version type use the matching upgrade channel, the energy storage devices to be upgraded can complete the software upgrade corresponding to the general upgrade protocol.

[0039] It can be understood that the present invention is sorted out according to the different points of the energy storage devices to be upgraded in different version types. Among them, the energy storage device to be upgraded in the first version uses a three-layer architecture, and the second chip BSMU of the slave control performs preliminary collection and data processing, and transmits it to the first chip BCMU of the master control. The energy storage device to be upgraded in the second version can be called a second-generation product and an all-in-one product. Compared with the energy storage device to be upgraded in the first version, the energy storage device to be upgraded in the second version directly omits the second chip BSMU of the slave control and adopts a two-layer architecture. The energy storage device to be upgraded in the third version needs to be operated in parallel because there is a demand for parallel expansion. The two clusters of the first chip BCMU no longer directly control the system, but follow the instructions of the third chip BAMU for control, etc. This application performs software adaptation according to a specific demand environment or different identification codes of different versions of the energy storage to be upgraded. After the configuration is completed, the low voltage power can be re-upgraded to match the current usage scenario.

[0040] In some application scenarios, the energy storage device to be upgraded in the first version can be called a first-generation stacking product. The specific use scenarios of the energy storage device to be upgraded in the first version include: a system composed of multiple packs, each pack has an independent second chip BSMU, and each second chip BSMU communicates with the first chip BCMU to achieve upper and lower high voltage. In order to avoid communication address conflicts between different second chip BSMUs and the first chip BCMU, generally speaking, there is one first chip BCMU and the second chip BSMU consists of 1-8 (limited by the working voltage of each component). This project introduces an address self-allocation solution. The first chip BCMU initiates the allocation process to the second chip BSMU. When the ID allocation is completed, the second chip BSMU and the first chip BCMU communicate normally, and the data of which pack is distinguished by the different IDs.

[0041] In some application scenarios, the energy storage equipment to be upgraded in the second version can be called a second-generation stacking product. The second chip BSMU in each pack is cancelled, and only the daisy chain is responsible for the single-unit collection. In terms of usage scenarios, the energy storage equipment to be upgraded in the second version is more inclined to the architecture of an all-in-one machine. The difference is that the power of the second-generation stacking product can be determined by the customer himself, and the point quantity can be increased or decreased by adding or reducing packs, while the power of the all-in-one machine is fixed at the factory.

[0042] In some application scenarios, the energy storage device to be upgraded in the third version can be used when the customer is not satisfied with the household use scenario of 25 kWh. Considering that the height of the stacked pack is too high, there is a safety hazard. Moreover, the increase in the voltage platform makes some components unsupported in this environment, so the parallel use solution is introduced. Multiple clusters can be used in parallel, and the host performs external communication and internal control.

[0043] It is understandable that, because the first chip in the energy storage device to be upgraded is in working state when the energy storage device to be upgraded is in different version types, the execution subject of the above software upgrade method can be the first chip in the energy storage device to be upgraded.

[0044] Step S12: based on the version type of the energy storage device to be upgraded, determining the target interaction mode of each chip in the energy storage device to be upgraded.

[0045] Based on the version type of the energy storage device to be upgraded, the target interaction mode of each chip in the energy storage device to be upgraded is determined so as to receive the software upgrade protocol sent by the preset device using the target interaction mode. The interaction mode of each chip is one of internal channel interaction, external channel interaction and internal-external channel interaction.

[0046] The software upgrade protocol sent by the preset device is received by using the target interaction method. The preset device is used for remote upgrade. The preset device may be the inverter mentioned above. The software upgrade protocol may be a general upgrade protocol. The software upgrade protocol is applicable to the upgrade process of all versions of the energy storage devices to be upgraded.

[0047] In some application scenarios, when the version type of the energy storage device to be upgraded is the first version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned first target interaction mode. Specifically, because the interaction mode of the first chip in the first target interaction mode is internal-external channel interaction. The inverter sends the software upgrade protocol to the first chip, and the first chip forwards the software upgrade protocol to the second chip, and the software upgrade of each chip can be completed. In some application scenarios, when the version type of the energy storage device to be upgraded is the second version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned second target interaction mode. Specifically, because the interaction mode of the first chip in the second target interaction mode is external channel interaction. The inverter sends the software upgrade protocol to the first chip, and the software upgrade of each chip can be completed. In some application scenarios, when the version type of the energy storage device to be upgraded is the third version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned third target interaction mode. Specifically, because the interaction mode of the third chip in the third target interaction mode is internal-external channel interaction. The inverter sends the software upgrade protocol to the third chip, and the third chip forwards the software upgrade protocol to the first chip, thereby completing the software upgrade of each chip.

[0048] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0049] See also Figure 2 , Figure 2 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 2 .

[0050] In some embodiments, the above step S12 may include the following steps: Step S21: Determine whether there is a target chip in each chip. The target interaction mode of the target chip is inconsistent with the current interaction mode of the chip. Step S22: Adjust the current interaction mode of the target chip to the target interaction mode.

[0051] In the process of upgrading the energy storage device to be upgraded, it may be an adjustment between the version types of the energy storage device to be upgraded. In some application scenarios, the energy storage device to be upgraded can be adjusted from the first version to the third version, or from the second version to the third version. Specifically, the target interaction mode may be the third target interaction mode corresponding to the third version. In some application scenarios, when the first version is adjusted to the third version, the current interaction mode may be the first target interaction mode. At this time, the target chips are the first chip, the second chip and the third chip respectively. The above step S22 may be a process of adjusting from the first target interaction mode to the third target interaction mode. Specifically, the interaction mode of the first chip in the target chip is adjusted from the internal-external channel interaction to the internal channel interaction. The second chip in the target chip is adjusted from the working state to the dormant state. The third chip in the target chip is adjusted from the dormant state to the internal-external channel interaction. When the second version is adjusted to the third version, the above step S22 may be a process of adjusting from the second target interaction mode to the third target interaction mode, and the specific process is not repeated here.

[0052] In other application scenarios, the energy storage device to be upgraded can be adjusted from the third version to the first version, or from the third version to the second version. In the process of adjusting between the version types of the energy storage device to be upgraded, it involves switching the working mode of each chip in the energy storage device to be upgraded. In the case where the third version is adjusted to the first version, the above-mentioned step S22 can be adjusted from the above-mentioned third target interaction mode to the process of the first target interaction mode, and the specific process will not be repeated here. In the case where the third version is adjusted to the second version, the above-mentioned step S22 can be adjusted from the above-mentioned third target interaction mode to the process of the second target interaction mode, and the specific process will not be repeated here.

[0053] In addition, the present application also takes into account that in the process of software upgrading the energy storage devices to be upgraded of different version types, the energy storage devices to be upgraded of different version types may have different relay control logic. After the above step S11, according to the determination of different version types, the control instructions sent to the relay by the target software corresponding to the energy storage devices to be upgraded of different version types may be the same or different. Therefore, the present application can also perform preset processing on the relays of the energy storage devices to be upgraded of different version types, so that the relays in the energy storage devices to be upgraded after preset processing can receive the control instructions sent by the target software and execute the control functions related to the control instructions. The above preset processing can be relay control. Specifically, in some application scenarios, when the version type determined in the above step S11 is the first version, it is necessary to additionally control the relays in the above pack, specifically: first close the relays in the pack, and then uniformly control the same relays in all version types, and the same relays are the above high-voltage box relays. In other application scenarios, when the version type determined in the above step S11 is the second version or the third version, the same relays in all version types are uniformly controlled, and the same relays are the above high-voltage box relays.

[0054] In some application scenarios, when the first version is adjusted to the third version, in response to the voltage difference corresponding to the two first chips being less than or equal to the preset voltage difference, the relays in the pack corresponding to the two first chips are directly closed first, and then the main negative relay and the pre-charge relay in the high-voltage box are closed, and the main positive relay is closed after the pre-charge is completed, and the pre-charge relay is disconnected. It can be understood that the step of uniformly controlling the same relays in all version types can be closing the main negative relay and the pre-charge relay in the high-voltage box, closing the main positive relay after the pre-charge is completed, and disconnecting the pre-charge relay. In other application scenarios, when the second version is adjusted to the third version, the above-mentioned step of uniformly controlling the same relays in all version types is directly executed.

[0055] In some application scenarios, when the third version is adjusted to the first version or the second version, the third chip BAMU control is adjusted to the first chip BCMU control. It is understandable that different chip controls are used for the chip to send control instructions to the relay to implement control functions related to the control instructions.

[0056] It can be considered that by adjusting the current interaction mode of the target chip to the target interaction mode, the upgrade channel configuration of the energy storage device to be upgraded can be realized, so as to receive the software upgrade protocol sent by the preset device using the target interaction mode, thereby completing the software upgrade of the energy storage devices to be upgraded corresponding to different version types using a general software upgrade protocol, realizing software reuse, and thus improving the efficiency of software upgrade.

[0057] In some embodiments, the version type is one of the first version, the second version, and the third version, wherein the first chip and the second chip in the energy storage device to be upgraded in the first version are in working state, the first chip in the energy storage device to be upgraded in the second version is in working state, and the first chip and the third chip in the energy storage device to be upgraded in the third version are in working state, and the above-mentioned step of adjusting the current interaction mode of the target chip to the target interaction mode may include the following steps: in response to the version type being the first version, the first chip is set as an external channel and the second chip is set as an internal channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device. Or, in response to the version type being the second version, the first chip is set as an external channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device. Or. In response to the version type being the third version, the first chip is set as an internal channel and the third chip is set as an external channel so as to use the third chip in the external channel to receive the software upgrade protocol sent by the preset device.

[0058] The step of adjusting the current interaction mode of the target chip to the target interaction mode may be to configure the channels of each chip in the energy storage device to be upgraded based on the target interaction mode. The internal channel may be a channel that communicates only with each chip. The external channel may be a channel that the chip can communicate with the above-mentioned preset device.

[0059] In some application scenarios, when the version type of the energy storage device to be upgraded is the first version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned first target interaction mode. The first chip is set as an external channel so that the interaction mode of the first chip is internal-external channel interaction. The first chip can communicate internally with the second chip, and the first chip can communicate externally with a preset device. The second chip is set as an internal channel to realize internal communication between the first chip and the second chip. The inverter sends the software upgrade protocol to the first chip, and the first chip forwards the software upgrade protocol to the second chip, and the software upgrade of each chip can be completed.

[0060] In some application scenarios, when the version type of the energy storage device to be upgraded is the second version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned second target interaction mode. The first chip is set as an external channel so that the interaction mode of the first chip is external channel interaction. The first chip is implemented to communicate externally only with the preset device. The software upgrade of each chip can be completed by using the first chip in the external channel to receive the software upgrade protocol sent by the inverter. Among them, the inverter sends the software upgrade protocol to the first chip to complete the software upgrade of each chip.

[0061] In some application scenarios, when the version type of the energy storage device to be upgraded is the third version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned third target interaction mode. The third chip is set as an external channel so that the interaction mode of the third chip is internal-external channel interaction. It is realized that the third chip can communicate internally with the first chip, and it is also possible that the third chip can communicate externally with a preset device. The first chip is set as an internal channel to realize internal communication between the first chip and the third chip. The inverter sends the software upgrade protocol to the third chip, and the third chip forwards the software upgrade protocol to the first chip, thereby completing the software upgrade of each chip. Specifically, because the interaction mode of the third chip in the third target interaction mode is internal-external channel interaction. The inverter sends the software upgrade protocol to the third chip, and the third chip forwards the software upgrade protocol to the first chip, thereby completing the software upgrade of each chip.

[0062] It can be considered that, based on the target interaction mode, the channels of the chips in the energy storage device to be upgraded are configured so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode, thereby completing the software upgrade of the energy storage devices to be upgraded corresponding to different version types using the general software upgrade protocol, realizing software reuse, and thus improving the efficiency of software upgrade.

[0063] See also Figure 3 , Figure 3 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 3 .

[0064] In some embodiments, the above step S11 may include the following steps: Step S31: Determine whether the energy storage device to be upgraded has an address self-allocation function. The address self-allocation function is used to perform an identification allocation work to the second chip. Step S32: In response to the energy storage device to be upgraded having an address self-allocation function, determine the version type of the energy storage device to be upgraded as the first version.

[0065] The address self-allocation function is used by the first chip to perform the identification assignment work to the second chip. The address self-allocation function can also be an ID self-allocation process. The energy storage device to be upgraded has the address self-allocation function, which means that the identification assignment work to the second chip is successfully performed, that is, at least part of the second chip is successfully assigned an identification.

[0066] Exemplarily, the energy storage device to be upgraded is powered by a low voltage, for example, 12V low voltage.

[0067] Then, each chip in the energy storage device to be upgraded begins to initialize, including the initialization of the underlying data, driver and application layer data, and obtains relevant initialization data. The received initialization data is judged and processed. The first chip BCMU (battery cluster management unit) in the energy storage device to be upgraded initiates the ID self-allocation process. If there is a second chip BSMU (battery system management unit), it will reply. The reply can be that the identification allocation work to the second chip is successfully executed. The existence of a reply indicates that there are a first chip and a second chip in a working state in the energy storage device to be upgraded. Furthermore, because only the first version has a first chip and a second chip in a working state among the first version, the second version and the third version, it indicates that the version type of the energy storage device to be upgraded at this time is the first version.

[0068] In other application scenarios, after the above step S31, in response to the energy storage device to be upgraded not having the function of self-allocation of addresses, the version type of the energy storage device to be upgraded is determined as a candidate version type. The fact that the energy storage device to be upgraded does not have the function of self-allocation of addresses may be due to the failure to perform the work of allocating identifiers to the second chip, that is, any second chip has not been successfully allocated an identifier within the threshold time. The candidate version type may be one of the above-mentioned second version and third version. Exemplarily, if no reply is received from the second chip BSMU (battery system management unit), it means that there is no second chip BSMU (battery system management unit), and it is determined to be a second-generation project or a parallel project corresponding to the candidate version type.

[0069] It can be considered that by comparing the first version, the second version and the third version, only the first version can be used to assign an identifier to the second chip. By using this standard to determine whether the version type is the first version, the efficiency of determining the version type of the energy storage device to be upgraded can be improved.

[0070] In some embodiments, the energy storage device to be upgraded in the first version includes multiple second chips, and the step of setting the first chip as an external channel and the second chip as an internal channel in response to the version type being the first version may include the following: in response to the version type being the first version, performing self-addressing on each second chip to obtain each allocated second chip. The target interaction mode is determined as the first chip being set as an external channel and each allocated second chip being set as an internal channel.

[0071] The allocated second chips may each have an identification indicating that the second chips are successfully allocated.

[0072] The process of self-assigning addresses to each second chip may include: in some application scenarios, the first chip BCMU pulls down the hard line, regularly sends a clear original number instruction to each second chip BSMU with a period of 100ms, and assigns invalid ID 0 to each second chip BSMU, pulling down the second chip BSMU hard line. In some application scenarios, the first chip BCMU detects that the second chip BSMU hard line is low, and does not receive a message with ID 0 for one second, then starts the ID assignment work, the second chip BSMU receives the instruction, and sets the ID to 0. If the requirements are not met within 5S, the ID assignment work is stopped, and after reporting the communication error, the technician will check the wiring harness link. In some application scenarios, after the first chip BCMU enters the first ID assignment workflow, it first performs hard line output open circuit fault diagnosis, and if there is a fault, reports the fault, the assignment fails, and the technician checks the problem. If there is no fault, the first chip BCMU pulls up the hard line and sends an address allocation message to the first and second chip BSMU. After receiving the message instruction, the second chip BSMU replies with the assigned ID number 1. After receiving the reply information from each second chip BSMU, the first chip BCMU believes that the first and second chip BSMU has completed the ID allocation. The first and second chip BSMU pull up the hard line and perform hard line output open circuit diagnosis. In some application scenarios, after completing the first ID allocation work, the first chip BCMU performs detection work to check whether there is still data received for the default ID. If there is, the above process is repeated, and the first chip BCMU performs ID allocation work to the second and second chip BSMU until it is detected that all second chip BSMU hard lines are pulled high, and the first chip BCMU no longer receives ID data. The ID allocation work is completed, and each second chip BSMU obtains its own ID number. If the host does not receive the reply message from each second chip BSMU for more than 5S, the fault is reported and the technicians will investigate.

[0073] The above-mentioned determination of the target interaction mode as setting the first chip as an external channel and setting each allocated second chip as an internal channel may include: setting the first chip as an external channel so that the interaction mode of the first chip is internal-external channel interaction. Setting the allocated second chip as an internal channel realizes internal communication between the first chip and the allocated second chip. The inverter sends the software upgrade protocol to the first chip, and the first chip forwards the software upgrade protocol to each allocated second chip, thereby completing the software upgrade of each chip.

[0074] It can be considered that in a multi-chip system, each chip usually needs to have a unique address so that the main control chip can communicate with them. Traditionally, this is achieved through a dip switch, and the address of each chip is determined by setting the position of the dip switch. However, the traditional method is costly and manually setting the dip switch is prone to errors, which may cause system failures. The present application obtains the second chip after each allocation through address self-allocation, which can automate address allocation to reduce human errors, improve system reliability, and thus improve the efficiency of software upgrades.

[0075] See also Figure 4 , Figure 4 This is a flowchart of an embodiment of the software upgrade method of the present application. Figure 4 .

[0076] In some embodiments, the software upgrade method further includes: step S41: in response to the energy storage device to be upgraded not having the address self-allocation function, determining whether the energy storage device to be upgraded has master-slave communication. Step S42: in response to the energy storage device to be upgraded not having master-slave communication, determining the version type of the energy storage device to be upgraded as the second version. Or, step S43: in response to the energy storage device to be upgraded having master-slave communication, determining the version type of the energy storage device to be upgraded as the third version.

[0077] The master-slave communication may be the master-slave communication of each chip in the energy storage device to be upgraded. Specifically, the master-slave communication may be whether the types of each chip in the working state in the energy storage device to be upgraded are different.

[0078] In some application scenarios, when the energy storage device to be upgraded does not have the function of self-allocation of addresses, the absence of master-slave communication in the energy storage device to be upgraded can indicate that the type of each chip in the working state in the energy storage device to be upgraded is only one. That is, the type of each chip in the working state in the energy storage device to be upgraded is only the first chip, and the version type of the energy storage device to be upgraded is determined to be the second version.

[0079] In other application scenarios, when the energy storage device to be upgraded does not have the address self-allocation function, the existence of master-slave communication in the energy storage device to be upgraded can indicate that the types of chips in the energy storage device to be upgraded are multiple. That is, the chips in the energy storage device to be upgraded that are in working state can be the first chip and the third chip, and the version type of the energy storage device to be upgraded is determined to be the third version.

[0080] It can be considered that by comparing the first version, the second version and the third version, when the energy storage device to be upgraded does not have the address self-allocation function, only the third version has master-slave communication. By using this standard to determine whether the version type is the third version or the second version, the efficiency of determining the version type of the energy storage device to be upgraded can be improved.

[0081] In some embodiments, the energy storage device to be upgraded in the third version includes a plurality of third chips, and in response to the version type being the third version, the first chip is set as an internal channel and the third chip is set as an external channel, including: in response to the version type being the third version, cluster addresses are assigned to each third chip to obtain each assigned third chip. The target interaction mode is determined as the first chip is set as an internal channel and each assigned third chip is set as an external channel.

[0082] When the energy storage device to be upgraded is in the third version, the energy storage device to be upgraded is composed of several battery clusters instead of a single cluster, so each battery cluster needs to be numbered. Cluster address allocation is used to number each battery cluster in the energy storage device to be upgraded. The above-mentioned several battery clusters may be the first battery cluster where the third chip is located. The above-mentioned several battery clusters may be the second battery cluster where the first chip and / or the second chip is located. It can be understood that in the application scenario where the above-mentioned energy storage device to be upgraded is adjusted from the first version to the third version, or from the second version to the third version, the battery pack managed by the first chip and the second chip in the original first version, or the battery pack managed by the first chip in the second version, is used as the second battery cluster by default because the high-voltage box in the energy storage device to be upgraded in the third version is special and contains the third chip BAMU inside, so the battery pack managed by the third chip BAMU in the working state will be switched as the first battery cluster.

[0083] When the version type of the energy storage device to be upgraded is the third version, the target interaction mode of each chip in the energy storage device to be upgraded is determined to be the above-mentioned third target interaction mode. The allocated third chip is set as an external channel so that the interaction mode of the allocated third chip is internal-external channel interaction. The allocated third chip can communicate internally with the first chip, and the allocated third chip can also communicate externally with the preset device. The first chip is set as an internal channel to realize internal communication between the first chip and the allocated third chip. The inverter sends the software upgrade protocol to the allocated third chip, and the allocated third chip forwards the software upgrade protocol to the first chip, so that the software upgrade of each chip can be completed. Specifically, because the interaction mode of the allocated third chip in the third target interaction mode is internal-external channel interaction. The inverter sends the software upgrade protocol to the allocated third chip, and the allocated third chip forwards the software upgrade protocol to the first chip, so that the software upgrade of each chip can be completed.

[0084] Exemplarily, the above-mentioned relay control process may include: when it is detected that the switching power supply is activated and powered on, the first chip BCMU and the second chip BSMU perform chip self-test. After the self-test is completed, the first chip BCMU receives the second chip BSMU data for verification and judgment. If the total voltage difference between cluster 1 and cluster 2 is 3V×the number of packs per cluster, and the power value (SOC) of cluster 1 and cluster 2 is within the preset percentage, it is considered that the direct parallel condition is met. For example, the power value (SOC, State of Charge) can refer to the charging state of the car battery. For example, the above-mentioned preset percentage can be 30%. If it is not met, it is considered that the direct parallel condition is not met. It can be understood that when the direct parallel condition is not met, it is necessary to perform separate charging operations before executing the steps performed when the direct parallel condition is met.

[0085] Specifically, when the direct parallel conditions are met, the following steps are performed: give priority to the high voltage of the slave cluster, close the main negative relay and the pre-charge relay to enter the field for pre-charging, and when the voltage difference between the front and rear ends of the pre-charge resistor (the difference between the battery terminal voltage BMS_FuseVol and the pre-charge resistor rear end voltage BMS_HVVol) is within 10 volts, it is considered that the high voltage condition is met, close the main positive relay, disconnect the pre-charge relay, and complete the high voltage operation of the slave cluster. After completing the high voltage of the slave cluster, the main cluster is operated for high voltage parallel operation, close the main negative relay and the pre-charge relay of the main cluster, and judge that the current of the main cluster at this time (there is a voltage difference between the two clusters, so there will be current) is within 1 amp, and the difference between the battery terminal voltage BMS_FuseVol and the pre-charge resistor rear end voltage BMS_HVVol is within 5V for 3S, close the main positive relay of the main cluster, and disconnect the pre-charge relay. Specifically, when the direct parallel conditions are not met, the following steps are performed: the main cluster is pre-charged first, and charging is performed after the pre-charging is completed. After full charging is completed (the power is equal to 100% and the maximum single cell voltage is >3.55V and lasts for 3S), the main cluster relay is cut off, and the slave cluster is charged with high voltage. After charging is completed, it is idle for a preset time to enter the parallel process. It can be understood that entering the parallel process can be executing the above steps performed when the direct parallel conditions are met. The above preset time can be 10 minutes.

[0086] It is understandable that the above parallel condition may refer to that the energy storage device to be upgraded is in version 3. The above master cluster and the above cluster 1 may refer to the above first battery cluster. The above slave cluster and the above cluster 2 may refer to the above second battery cluster.

[0087] It can be considered that in a multi-chip system, each chip usually needs to have a unique address so that the main control chip can communicate with them. Traditionally, this is achieved through a dip switch, and the address of each chip is determined by setting the position of the dip switch. However, the traditional method is costly and manually setting the dip switch is prone to errors, which may cause system failures. The present application obtains the third chip after each allocation through cluster address self-allocation, which can automate address allocation to reduce human errors, improve system reliability, and thus improve the efficiency of software upgrades.

[0088] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0089] See also Figure 5 , Figure 5 It is a structural diagram of an embodiment of the software upgrade device of the present application. The software upgrade device 50 is arranged in the energy storage device to be upgraded, and the software upgrade device 50 includes a first determination module 51 and a second determination module 52. The first determination module 51 is used to determine the version type of the energy storage device to be upgraded; the second determination module 52 is used to determine the target interaction mode of each chip in the energy storage device to be upgraded based on the version type of the energy storage device to be upgraded. It can be understood that the software upgrade device 50 can be arranged in the first chip. Among them, the management unit related to the first chip is a battery system management unit (Battery System Management Unit, BSMU).

[0090] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0091] For the functions performed by each module, please refer to the software upgrade method, which will not be repeated here.

[0092] See also Figure 6 , Figure 66 is a schematic diagram of the structure of an embodiment of a vehicle of the present application. The electronic device 60 includes a memory 61 and a processor 62, and the processor 62 is used to execute program instructions stored in the memory 61 to implement the steps in the above software upgrade method embodiment. In a specific implementation scenario, the electronic device 60 may include but is not limited to: a microcomputer, a server, and in addition, the electronic device 60 may also include a mobile device such as a laptop computer and a tablet computer, which is not limited here.

[0093] Specifically, the processor 62 is used to control itself and the memory 61 to implement the steps in the above-mentioned software upgrade method embodiment. The processor 62 can also be called a CPU (Central Processing Unit). The processor 62 may be an integrated circuit chip with signal processing capabilities. The processor 62 can also be a general-purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field-programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. In addition, the processor 62 can be implemented by an integrated circuit chip.

[0094] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0095] See also Figure 7 , Figure 7 The computer-readable storage medium 70 stores program instructions 701, which implement the steps in any of the above software upgrade method embodiments when executed by a processor.

[0096] The above scheme determines the version type of the energy storage device to be upgraded, and based on the version type of the energy storage device to be upgraded, determines the target interaction mode of each chip in the energy storage device to be upgraded so as to receive the software upgrade protocol sent by the preset device by using the target interaction mode. It can use a common software upgrade protocol to perform software upgrade on energy storage devices to be upgraded corresponding to different version types, realize software reuse, and thus improve the efficiency of software upgrade.

[0097] In some embodiments, the functions or modules included in the system provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.

[0098] The above description of various embodiments tends to emphasize the differences between the various embodiments. The same or similar aspects can be referenced to each other, and for the sake of brevity, they will not be repeated herein.

[0099] In the several embodiments provided in the present application, it should be understood that the disclosed methods and devices can be implemented in other ways. For example, the device implementation described above is only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation, such as 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, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.

[0100] 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.

[0101] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially 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, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) or a processor (processor) to perform all or part of the steps of each implementation method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.

Claims

1. A software upgrade method, characterized in that: The software upgrade method is applied to the energy storage device to be upgraded, and the method comprises: Determining the version type of the energy storage device to be upgraded; Based on the version type of the energy storage device to be upgraded, a target interaction mode of each chip in the energy storage device to be upgraded is determined so as to receive a software upgrade protocol sent by a preset device using the target interaction mode, and the interaction mode of each chip is one of internal channel interaction, external channel interaction and internal-external channel interaction.

2. The method according to claim 1, characterized in that The determining, based on the version type of the energy storage device to be upgraded, a target interaction mode of each chip in the energy storage device to be upgraded includes: Determining whether there is a target chip in each of the chips, wherein the target interaction mode of the target chip is inconsistent with the current interaction mode of the chip; The current interaction mode of the target chip is adjusted to the target interaction mode.

3. The method according to claim 2, characterized in that The version type is one of a first version, a second version, and a third version, wherein the first chip and the second chip in the energy storage device to be upgraded in the first version are in a working state, the first chip in the energy storage device to be upgraded in the second version is in a working state, and the first chip and the third chip in the energy storage device to be upgraded in the third version are in a working state, The step of adjusting the current interaction mode of the target chip to the target interaction mode includes: In response to the version type being the first version, setting the first chip as an external channel and the second chip as an internal channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device; or, In response to the version type being the second version, setting the first chip as an external channel so as to use the first chip in the external channel to receive the software upgrade protocol sent by the preset device; or; In response to the version type being the third version, the first chip is set as an internal channel and the third chip is set as an external channel so as to use the third chip in the external channel to receive the software upgrade protocol sent by the preset device.

4. The method according to claim 3, characterized in that Determining the version type of the energy storage device to be upgraded includes: Determine whether the energy storage device to be upgraded has an address self-allocation function, where the address self-allocation function is used to perform an identification allocation work on the second chip; In response to the energy storage device to be upgraded having an address self-allocation function, the version type of the energy storage device to be upgraded is determined to be the first version.

5. The method according to claim 4, characterized in that The method further comprises: In response to the energy storage device to be upgraded not having an address self-allocation function, determining whether there is master-slave communication between the energy storage device to be upgraded; In response to the absence of master-slave communication in the energy storage device to be upgraded, determining the version type of the energy storage device to be upgraded as the second version; or, In response to the existence of master-slave communication in the energy storage device to be upgraded, the version type of the energy storage device to be upgraded is determined to be the third version.

6. The method according to claim 3, characterized in that: The energy storage device to be upgraded in the first version includes a plurality of the second chips, and in response to the version type being the first version, setting the first chip as an external channel and the second chip as an internal channel includes: In response to the version type being the first version, performing self-address allocation on each of the second chips to obtain each allocated second chip; The target interaction mode is determined as that the first chip is set as an external channel and each of the allocated second chips is set as an internal channel.

7. The method according to claim 3, characterized in that The energy storage device to be upgraded in the third version includes a plurality of the third chips, and in response to the version type being the third version, setting the first chip as an internal channel and the third chip as an external channel comprises: In response to the version type being the third version, performing cluster address allocation on each of the third chips to obtain each allocated third chip; The target interaction mode is determined as that the first chip is set as an internal channel and each of the allocated third chips is set as an external channel.

8. A software upgrade device, characterized in that: The software upgrade device is arranged in the energy storage device to be upgraded, and includes: A first determination module, used to determine the version type of the energy storage device to be upgraded; The second determination module is used to determine the target interaction mode of each chip in the energy storage device to be upgraded based on the version type of the energy storage device to be upgraded.

9. An electronic device, characterized in that: include: A memory and a processor, wherein the memory stores program instructions, and the processor retrieves the program instructions from the memory to execute the method according to any one of claims 1 to 7.

10. A computer-readable storage medium having program instructions stored thereon, characterized in that: When the program instructions are executed by a processor, they are used to implement the method according to any one of claims 1 to 7.