Circuit breaker parameter setting method and device, electronic equipment and storage medium

By establishing a mapping relationship between devices and location identifiers on the cloud platform, the circuit breaker parameters before replacement are automatically sent out, solving the problem of low efficiency in parameter setting during circuit breaker replacement and achieving efficient one-click setting without manual intervention.

CN121863699APending Publication Date: 2026-04-14LIANGYUN SMART ENERGY (GUANGDONG) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-10
Publication Date
2026-04-14

AI Technical Summary

Technical Problem

Existing technologies have low efficiency and are time-consuming and labor-intensive when replacing circuit breakers. Existing ID generation algorithms do not fully consider the characteristics of IoT devices, resulting in device IDs being unrelated to specific device information.

Method used

By generating device identifiers and location identifiers, a mapping relationship is established and stored in the cloud platform database. The cloud platform monitors the circuit breaker status in real time and automatically sends the parameters of the circuit breaker before replacement to the circuit breaker after replacement, realizing one-click setting.

Benefits of technology

Without the need for professional technicians, the circuit breaker parameters are set automatically, improving the efficiency and consistency of parameter setting during replacement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121863699A_ABST
    Figure CN121863699A_ABST
Patent Text Reader

Abstract

The invention provides a circuit breaker parameter setting method and device, electronic equipment and a storage medium, and relates to the technical field of electric power intelligence. The method comprises the following steps: according to circuit breaker monitoring information, determining whether a circuit breaker deployed at an installation position is replaced or not; if the circuit breaker deployed at the installation position is replaced, obtaining circuit breaker parameters of the circuit breaker before replacement deployed at the installation position according to a pre-constructed mapping relation and a position identifier corresponding to the installation position, and sending the circuit breaker parameters of the circuit breaker before replacement to a circuit breaker after replacement deployed at the installation position, and setting the circuit breaker parameters of the replaced circuit breaker as the circuit breaker parameters of the circuit breaker before replacement. Whether the circuit breaker is replaced or not is monitored through the cloud platform, the server issues the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement when the circuit breaker is replaced, the cloud platform automatically completes circuit breaker parameter setting, manual intervention is not needed, and the circuit breaker parameter setting efficiency is effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of power intelligent technology, and more specifically, to a circuit breaker parameter setting method, device, electronic device, and storage medium. Background Technology

[0002] With the development of intelligent power distribution technology, circuit breakers are becoming increasingly intelligent, and their parameter settings are becoming more and more complex. When a circuit breaker in a certain installation location is replaced, in order to ensure that the new circuit breaker can operate in the same way as the old one, the parameter settings of the old circuit breaker need to be reapplied to the new circuit breaker.

[0003] Existing circuit breaker parameter setting methods often require technicians to perform complex reconfigurations of the new circuit breaker's parameters when replacement is needed, a process that is both time-consuming and labor-intensive. Furthermore, applying the parameter settings of the old circuit breaker to the new one relies on device identifiers (IDs). However, existing ID generation algorithms primarily depend on server information and do not fully consider the characteristics of IoT devices, resulting in generated device IDs that cannot be effectively associated with specific device information. Therefore, improving the efficiency of parameter setting when circuit breakers are replaced is one of the urgent problems to be solved in this field. Summary of the Invention

[0004] The purpose of this application is to address the shortcomings of the prior art by providing a circuit breaker parameter setting method, device, electronic device, and storage medium to solve the problems of low efficiency and time-consuming and labor-intensive parameter setting when the circuit breaker is replaced.

[0005] To achieve the above objectives, the technical solutions adopted in the embodiments of this application are as follows:

[0006] In a first aspect, embodiments of this application provide a method for setting circuit breaker parameters, the method comprising:

[0007] Based on the circuit breaker monitoring information, it is determined whether the circuit breaker deployed at the installation location has been replaced. The circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker. The equipment identifier is used to indicate the equipment information when the circuit breaker is connected to the network.

[0008] If the circuit breaker deployed at the installation location is replaced, the circuit breaker parameters of the previous circuit breaker deployed at the installation location are obtained according to the pre-built mapping relationship and the location identifier corresponding to the installation location. The circuit breaker parameters of the previous circuit breaker are then sent to the replaced circuit breaker deployed at the installation location, so that the replaced circuit breaker sets its circuit breaker parameters to those of the previous circuit breaker. The mapping relationship is used to indicate the association between the location identifier, the device identifier, and the circuit breaker parameters corresponding to the device identifier.

[0009] Secondly, embodiments of this application provide a circuit breaker parameter setting device, the device comprising:

[0010] The determination module is used to determine whether the circuit breaker deployed at the installation location has been replaced based on the circuit breaker monitoring information. The circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker, and the equipment identifier is used to indicate the equipment information when the circuit breaker was connected to the network.

[0011] The processing module is configured to, if the circuit breaker deployed at the installation location is replaced, obtain the circuit breaker parameters of the circuit breaker before replacement deployed at the installation location based on a pre-built mapping relationship and the location identifier corresponding to the installation location, and send the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement deployed at the installation location, so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement, wherein the mapping relationship is used to indicate the association between the location identifier, the device identifier, and the circuit breaker parameters.

[0012] Thirdly, embodiments of this application provide an electronic device, including: a processor, a storage medium, and a bus. The storage medium stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the storage medium via the bus, and the processor executes the machine-readable instructions to perform the steps of the circuit breaker parameter setting method as described in any of the first aspects above.

[0013] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the circuit breaker parameter setting method as described in any of the first aspects above.

[0014] According to the circuit breaker parameter setting method, apparatus, electronic device, and storage medium of the present application embodiments, based on circuit breaker monitoring information, it is determined whether the circuit breaker deployed at the installation location has been replaced. If the circuit breaker deployed at the installation location has been replaced, the circuit breaker parameters of the circuit breaker before replacement deployed at the installation location are obtained according to a pre-constructed mapping relationship and the location identifier corresponding to the installation location. The circuit breaker parameters of the circuit breaker before replacement are sent to the circuit breaker after replacement deployed at the installation location, so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement. According to the embodiments of this application, the correspondence between the location identifier and the device identifier corresponding to the installation location, as well as the circuit breaker parameters corresponding to the device identifier, are pre-stored in a database provided by the cloud platform. The cloud platform determines whether the circuit breaker deployed at the installation location has been replaced by real-time monitoring and collecting circuit breaker monitoring information. If the circuit breaker has been replaced, the cloud platform queries the circuit breaker parameters of the circuit breaker before replacement from the database based on the mapping relationship used to indicate the association between the location identifier, the device identifier, and the circuit breaker parameters corresponding to the device identifier, and the location identifier corresponding to the installation location. The server then sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement, so that the circuit breaker after replacement sets its circuit breaker parameters to those of the circuit breaker before replacement. In this way, the server directly sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement, realizing one-click setting of the circuit breaker parameters after replacement. During this process, no professional technicians are required to set the parameters of the smart circuit breaker. When the cloud platform detects that the circuit breaker has been replaced, it automatically queries the database to retrieve the circuit breaker parameters of the circuit breaker before replacement and sends these parameters to the replaced circuit breaker via the server. In other words, the parameter setting after the circuit breaker is replaced is automatically completed by the cloud platform without manual intervention, which effectively improves the efficiency of parameter setting when the circuit breaker is replaced. Attached Figure Description

[0015] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0016] Figure 1 This paper shows a schematic diagram of the architecture of a circuit breaker parameter setting system provided in an embodiment of this application;

[0017] Figure 2 A schematic flowchart of a circuit breaker parameter setting method provided in an embodiment of this application is shown;

[0018] Figure 3A flowchart illustrating a mapping relationship construction method provided in an embodiment of this application is shown;

[0019] Figure 4 A flowchart illustrating a device identifier generation method provided in an embodiment of this application is shown;

[0020] Figure 5 A schematic flowchart of a location identifier generation method provided in an embodiment of this application is shown;

[0021] Figure 6 This illustration shows a schematic diagram of the structure of a circuit breaker parameter setting device according to an embodiment of this application;

[0022] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of this application is shown. Detailed Implementation

[0023] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the accompanying drawings in this application are for illustrative and descriptive purposes only and are not intended to limit the scope of protection of this application. Furthermore, it should be understood that the schematic drawings are not drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of this application. It should be understood that the operations in the flowcharts may not be implemented in sequence, and steps without logical contextual relationships may be reversed or implemented simultaneously. In addition, those skilled in the art, guided by the content of this application, may add one or more other operations to the flowcharts, or remove one or more operations from the flowcharts.

[0024] Furthermore, the described embodiments are merely some, not all, of the embodiments of this application. The components of the embodiments of this application described and illustrated herein can typically be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.

[0025] To enable those skilled in the art to use the content of this application, and in conjunction with the specific application scenario of "a one-click method for setting parameters of an intelligent circuit breaker based on hash and snowflake algorithms," the following implementation is provided. For those skilled in the art, the general principles defined herein can be applied to other embodiments and application scenarios without departing from the spirit and scope of this application. Although this application primarily describes a method for setting circuit breaker parameters, it should be understood that this is only an exemplary embodiment.

[0026] It should be noted that the term "comprising" will be used in the embodiments of this application to indicate the presence of the features declared thereafter, but does not exclude the addition of other features.

[0027] This application provides a method for setting circuit breaker parameters. A device identifier is generated based on device information and server information, and a location identifier is generated based on installation location information and server information. A mapping relationship is established based on the location identifier, device identifier, and corresponding circuit breaker parameters. This mapping relationship and the circuit breaker parameters are stored in a database on a cloud platform. The cloud platform monitors the circuit breaker status in real time and, based on the binding relationship between the device identifier and the location identifier, determines whether the circuit breaker deployed at the installation location has been replaced. If a circuit breaker replacement is detected, the server sends the circuit breaker parameters of the old circuit breaker to the new circuit breaker, completing one-click setting and seamless replacement of circuit breaker replacement parameters.

[0028] Figure 1 A schematic diagram of the architecture of a circuit breaker parameter setting system provided in an embodiment of this application is shown. (Refer to...) Figure 1 As shown, the circuit breaker parameter setting system includes a cloud platform and a server, on which a database is deployed. The cloud platform can poll the correspondence between the device identifier of the circuit breaker deployed at the installation location and the corresponding location identifier. If the correspondence obtained at different query times is inconsistent, it is determined that the circuit breaker deployed at that installation location has been replaced. The cloud platform then queries the circuit breaker parameters of the circuit breaker before replacement from the database deployed on the server, and the server sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement, so that the circuit breaker after replacement sets its circuit breaker parameters to those of the circuit breaker before replacement.

[0029] Based on this, the circuit breaker parameter setting system provided in this application embodiment does not require professional technicians to set the parameters of the intelligent circuit breaker. When the cloud platform detects that the circuit breaker deployed at the installation location has been replaced, it automatically queries the circuit breaker parameters of the circuit breaker before replacement stored in the database, and sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement through the server. That is, the parameter setting after the circuit breaker is replaced is automatically completed by the cloud platform and the server without manual intervention, which effectively improves the parameter setting efficiency when the circuit breaker is replaced.

[0030] The following is in conjunction with the above. Figure 1 The circuit breaker parameter setting system shown herein provides a detailed explanation of the circuit breaker parameter setting method provided in this application embodiment.

[0031] Figure 2 A flowchart illustrating a circuit breaker parameter setting method according to an embodiment of this application is shown. As one possible implementation, refer to... Figure 2 As shown, the method specifically includes the following steps:

[0032] S201. Based on the circuit breaker monitoring information, determine whether the circuit breaker deployed at the installation location has been replaced.

[0033] Optionally, the circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker, and the equipment identifier is used to indicate the equipment information when the circuit breaker is connected to the network.

[0034] Optionally, the cloud platform polls the correspondence between the location identifier and the device identifier corresponding to the installation location, and identifies whether the circuit breaker deployed at the installation location has been replaced based on the correspondence. For example, if the correspondence indicated by the circuit breaker monitoring information collected in two adjacent query times is inconsistent, it is determined that the circuit breaker deployed at the installation location has been replaced.

[0035] It should be noted that the device identifier in this application embodiment is generated based on the circuit breaker's device information and server information. Compared with traditional identifier generation methods that mostly use server information without involving device information, the device identifier generated in this application does not lack relevant information about IoT hardware devices, and the device identifier is associated with specific device information. That is, this application fully considers the characteristics of IoT devices and combines server information to ensure that the generated device identifier ID can be well associated with specific device information.

[0036] S202. If the circuit breaker deployed at the installation location is replaced, the circuit breaker parameters of the circuit breaker before replacement deployed at the installation location are obtained according to the pre-built mapping relationship and the location identifier corresponding to the installation location. The circuit breaker parameters of the circuit breaker before replacement are sent to the circuit breaker after replacement deployed at the installation location so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement.

[0037] Optionally, the mapping relationship is used to indicate the association between location identifiers, device identifiers, and the circuit breaker parameters corresponding to the device identifiers. For example, the mapping relationship is a way to store the correspondence between location identifiers and device identifiers. Based on the mapping relationship, it is helpful to quickly query which circuit breaker is specifically deployed at a certain installation location, and the circuit breaker parameters corresponding to the circuit breaker deployed at that installation location.

[0038] Optionally, when a circuit breaker replacement is detected, the cloud platform will determine the device identifier of the circuit breaker before replacement based on the pre-built mapping relationship and the location identifier corresponding to the installation location. It will then use the device identifier to look up the circuit breaker parameters of the circuit breaker before replacement, and the server will send the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement, so that the circuit breaker after replacement can inherit the parameter configuration of the circuit breaker before replacement, thereby maintaining the continuity and consistency of parameter settings when the circuit breaker is replaced.

[0039] Based on this, according to the circuit breaker parameter setting method provided in the embodiments of this application, the circuit breaker monitoring information is monitored and collected in real time through the cloud platform to determine whether the circuit breaker deployed at the installation location has been replaced. If the circuit breaker has been replaced, the circuit breaker parameters of the circuit breaker before replacement are queried from the database based on the pre-built mapping relationship and the location identifier corresponding to the installation location. The circuit breaker parameters of the circuit breaker before replacement are then sent to the circuit breaker after replacement through the server, so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement. In this way, the circuit breaker parameters of the circuit breaker before replacement are sent directly to the circuit breaker after replacement through the server, realizing one-click setting of the parameters of the circuit breaker after replacement. During this process, no professional technicians are required to set the parameters of the smart circuit breaker. When the cloud platform detects that the circuit breaker has been replaced, it automatically queries the database to retrieve the circuit breaker parameters of the circuit breaker before replacement and sends these parameters to the replaced circuit breaker via the server. In other words, the parameter setting after the circuit breaker is replaced is automatically completed by the cloud platform without manual intervention, which effectively improves the efficiency of parameter setting when the circuit breaker is replaced.

[0040] As one possible implementation, step S201 above determines whether the circuit breaker deployed at the installation location has been replaced based on the circuit breaker monitoring information, including:

[0041] The device identifiers of the circuit breakers deployed at the installation location are polled at preset intervals to obtain the device identifiers corresponding to the current query time and the next query time. If the first correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the current query time is inconsistent with the second correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the next query time, it is determined that the circuit breaker deployed at the installation location has been replaced.

[0042] Optionally, the cloud platform periodically polls the device identifiers of circuit breakers at the installation location and determines whether the circuit breakers have been replaced by comparing the device identifiers at different times. Each circuit breaker has a unique device identifier. The cloud platform periodically queries the device identifiers of circuit breakers at the installation location at preset time intervals. Each query records the current query time and the device identifier of the circuit breaker corresponding to the current query time. It then associates the device identifier corresponding to the installation location with the device identifier corresponding to the current query time to form a first correspondence. It also associates the device identifier corresponding to the installation location with the device identifier corresponding to the next query time to form a second correspondence. By comparing whether the first and second correspondences are consistent, if they are inconsistent, it is considered that the circuit breaker deployed at the installation location has been replaced.

[0043] For example, suppose a circuit breaker is deployed at installation location A, and the preset interval is ten minutes. The cloud platform polls once every ten minutes. The first query time T1 finds the device identifier at installation location A as ID1, forming a first correspondence relationship of "location A-ID1". The second query time T2 finds the device identifier at installation location A as ID2, forming a second correspondence relationship of "location A-ID2". If ID1 and ID2 are different, the first correspondence relationship and the second correspondence relationship are inconsistent, and it is therefore considered that the circuit breaker at installation location A has been replaced.

[0044] For example, the cloud platform can store the device identifier of the circuit breaker retrieved at each query time and the location identifier of the installation location for deploying the circuit breaker in a database according to a certain record format, such as: {Query Time: [Location Identifier, Device Identifier]}. By recording the location identifier and device identifier corresponding to each query time in the database, effective monitoring and management of the circuit breaker status can be achieved, which helps to improve the reliability and availability of the cloud platform.

[0045] Based on this, by periodically polling the setting identifiers of the circuit breakers deployed at the installation location, and recording and comparing the device identifiers of the circuit breakers at different polling times at the installation location, it is possible to detect whether the circuit breakers at the installation location have been replaced, thereby effectively monitoring the status changes of the circuit breakers deployed at the installation location.

[0046] Figure 3 A flowchart illustrating a mapping relationship construction method provided in an embodiment of this application is shown. As one possible implementation, refer to... Figure 3 As shown, before step S202 above, which obtains the circuit breaker parameters of the pre-replacement circuit breaker deployed at the installation location based on the pre-built mapping relationship and the location identifier corresponding to the installation location, the method further includes the following steps:

[0047] S301. Generate a device identifier based on the circuit breaker's device information and server information.

[0048] Optionally, device information can be obtained from the circuit breaker device, such as device model and manufacturer. Server information can be a unique identifier assigned to the server, determined by IP address, MAC address, or other means. Based on the obtained device and server information, a device identifier indicating the device information when the circuit breaker is connected to the network can be generated by combining snowflake algorithm and hash algorithm.

[0049] Figure 4 This illustration shows a flowchart of a device identifier generation method provided in an embodiment of this application. (Refer to...) Figure 4 As shown, step S301 specifically includes the following steps:

[0050] S401. Use a preset hash algorithm to perform hash operation on the device information and server information to generate a hash value of the first preset length.

[0051] For example, the preset hash algorithm can be the MD5 algorithm, and the output of the MD5 algorithm is a 32-bit hexadecimal string, so the corresponding first preset length is 32 bits. However, it should be noted that the length of the generated hash value will vary depending on the hash algorithm used.

[0052] For example, taking the MD5 algorithm as the preset hash algorithm, based on the obtained device information and server information, the device information and server information are first encoded into numerical form, and then the encoded device information and server information are combined into a string. Then, the MD5 algorithm is used to calculate the hash value of the combined string to generate a 32-bit hash value.

[0053] S402. Select a hash value of a first fixed length from the hash values ​​of the first preset length, and use the hash value of the first fixed length as the first device code.

[0054] For example, the first fixed length is 16 bits. Since the length of the hash value output by different hash algorithms is different, and the first device code in this embodiment is fixed at 16 bits, it is necessary to select a 16-bit hash value from the hash value of the first preset length generated by the preset hash algorithm as the first device code.

[0055] For example, taking the above example of "using the MD5 algorithm to calculate the hash value of the combined string and generate a 32-bit hash value", a fixed-length 16-bit hash value can be selected from the 32-bit hash value. You can choose to truncate the high 16 bits, low 16 bits, or truncate 16 bits from the middle to obtain a fixed-length 16-bit hash value.

[0056] S403. Based on the snowflake algorithm, the first device code, the second preset length timestamp, and the third preset length serial number are combined according to a preset format to generate a device identifier.

[0057] Optionally, the total length of the first device code, timestamp, and serial number satisfies a preset length value. Since the Snowflake algorithm is a distributed ID generation algorithm used to generate globally unique and ordered 64-bit integer IDs, the preset length value is 64 bits. Furthermore, the 64-bit ID generated by the Snowflake algorithm typically includes a timestamp, an identifier, and a serial number. Therefore, in the process of generating a device identifier based on the Snowflake algorithm, this application uses the first device code with a first fixed-length hash value as the identifier part in the Snowflake algorithm, the second preset-length timestamp as the timestamp part, and the third preset-length serial number as the serial number part to generate the device identifier. The second preset-length timestamp, the first device code, and the third preset-length serial number are arranged in order according to the arrangement of the IDs generated by the Snowflake algorithm to generate the device identifier.

[0058] For example, in this embodiment of the application, the 64-bit device identifier ID generated by the snowflake algorithm consists of 1 sign bit, n1 timestamp, n2 hash value and n3 serial number. Considering the actual storage time of IoT devices, n1 is set to 39 bits, which means that 17 years of data can be stored. n3 is set to 8 bits, which means that 256 data can be stored at the same time to meet application requirements. n2 is a fixed 16-bit hash value obtained based on hash algorithms such as MD5. Since the device information is taken into account in the 16-bit hash value, a link is established between the generated device identifier and the device information to meet the practical needs of IoT.

[0059] Based on this, a 16-bit hash value is generated according to the device information and server information, and this 16-bit hash value is used as the 16-bit device code in the snowflake algorithm to generate the device identifier.

[0060] S302. Generate a location identifier based on the circuit breaker's installation location information and server information.

[0061] Optionally, as mentioned above, the server information can be a unique identifier assigned to the server, determined by an IP address, MAC address, or other means, while the circuit breaker installation location information can include information about the installation location for deploying the circuit breaker, i.e., power distribution structure information. Based on obtaining the circuit breaker installation location information and server information, a location identifier indicating the circuit breaker's installation location can be generated by combining snowflake algorithms and hash algorithms.

[0062] Figure 5 The diagram shows a flowchart of a location identifier generation method provided in an embodiment of this application.

[0063] Reference Figure 5 As shown, step S302 specifically includes the following steps:

[0064] S501. Use a preset hash algorithm to perform hash operation on the installation location information and server information to generate a hash value of the fourth preset length.

[0065] For example, continuing with the example where the preset hash algorithm is MD5, the output of the MD5 algorithm is a 32-bit hexadecimal string, so the corresponding fourth preset length is 32 bits. Similarly, based on the obtained installation location information and server information, the installation location information and server information are first encoded into numerical form, and then the encoded installation location information and server information are combined into a string. Then, the MD5 algorithm is used to calculate the hash value of the combined string, generating a 32-bit hash value.

[0066] S502. Select a hash value of a second fixed length from the hash values ​​of the fourth preset length, and use the hash value of the second fixed length as the second device code.

[0067] For example, the fourth fixed length is 16 bits. Since the length of the hash value output by different hash algorithms is different, and the first device code in this embodiment is fixed at 16 bits, it is necessary to select a 16-bit hash value from the first preset length hash value generated by the preset hash algorithm as the first device code. Similarly, taking the above example of "using the MD5 algorithm to calculate the hash value of the combined string and generate a 32-bit hash value", a fixed length of 16 bits can be selected from the 32-bit hash value. This can be done by selecting the high 16 bits, the low 16 bits, or 16 bits from the middle of the 32-bit hash value to obtain a fixed length of 16 bits.

[0068] S503. Based on the snowflake algorithm, the second device code, the fifth preset length timestamp, and the sixth preset length serial number are combined according to a preset format to generate a location identifier.

[0069] For example, in the process of generating a location identifier based on the snowflake algorithm, the second device code with a second fixed-length hash value is used as the identifier part in the snowflake algorithm, the fifth preset-length timestamp is used as the timestamp part in the snowflake algorithm, and the sixth preset-length serial number is used as the serial number part in the snowflake algorithm to generate the device identifier. The fifth preset-length timestamp, the second device code, and the sixth preset-length serial number are arranged in order according to the arrangement order corresponding to the ID generated by the snowflake algorithm to generate the location identifier.

[0070] Based on this, a 16-bit hash value is generated according to the installation location information and server information, and this 16-bit hash value is used as the 16-bit device code in the snowflake algorithm to generate the location identifier.

[0071] S303. Based on the device identifier, location identifier, and circuit breaker parameters corresponding to the device identifier, construct a mapping relationship.

[0072] Optionally, the device identifier combines the circuit breaker's device information and server information to form an identifier that uniquely identifies the circuit breaker, and the location identifier combines the circuit breaker's installation location information and server information to form an identifier that uniquely identifies the circuit breaker's installation location. Based on this, the correspondence between the device identifier and the location identifier, as well as the association between the device identifier, the location identifier, and the circuit breaker parameters corresponding to the device identifier, are constructed as a mapping relationship, and this mapping relationship is stored in a database deployed on a cloud platform or server. For example, the mapping relationship can be stored in the form of a database table or a dictionary structure.

[0073] Based on this, a mapping relationship is pre-built to indicate the association between location identifier, device identifier, and circuit breaker parameters corresponding to the device identifier, so that the cloud platform can quickly identify whether the circuit breaker deployed at the installation location has been replaced based on the mapping relationship.

[0074] As one possible implementation, step S202 above obtains the circuit breaker parameters of the pre-replacement circuit breaker deployed at the installation location based on the pre-built mapping relationship and the location identifier corresponding to the installation location, including: determining the device identifier of the pre-replacement circuit breaker based on the mapping relationship and the location identifier corresponding to the installation location; and querying the circuit breaker parameters of the pre-replacement circuit breaker from a preset database based on the device identifier of the pre-replacement circuit breaker.

[0075] Optionally, a pre-built mapping relationship indicates the association between location identifiers, device identifiers, and the circuit breaker parameters corresponding to the device identifiers. Each installation location has a unique location identifier. Based on the location identifier corresponding to the installation location, the device identifier of the pre-replacement circuit breaker deployed at the installation location corresponding to the location identifier can be obtained by combining the mapping relationship. The circuit breaker parameters are pre-stored in a database. Based on the determined device identifier of the pre-replacement circuit breaker, the circuit breaker parameters of the pre-replacement circuit breaker are queried from the pre-set database.

[0076] Optionally, the default database includes a cache database and a relational database, which can be deployed on a server. The cache database typically uses a high-performance in-memory database, such as Redis, and is suitable for scenarios with large-scale devices and high timeliness requirements. It is used to store frequently accessed data to improve query efficiency. The relational database, such as MySQL, can persistently store circuit breaker parameters and is suitable for scenarios with small-scale devices or low timeliness requirements.

[0077] Optionally, based on the device identifier of the circuit breaker before replacement, the circuit breaker parameters of the circuit breaker before replacement are queried from the cache database; if the circuit breaker parameters of the circuit breaker before replacement are not found in the cache database, the circuit breaker parameters of the circuit breaker before replacement are queried from the relational database.

[0078] For example, when querying the circuit breaker parameters of the previous circuit breaker from the preset database, the Redis cache database can be queried first. If the parameters are not found in the Redis cache database, then the MySQL relational database is queried. Specifically, the device identifier of the previous circuit breaker is used as the query key. The circuit breaker parameters of the previous circuit breaker are first queried in the Redis cache database. If the corresponding circuit breaker parameters are found, the server sends the queried circuit breaker parameters of the previous circuit breaker to the circuit breaker deployed at the corresponding installation location. This allows the circuit breaker to set its circuit breaker parameters to those of the previous circuit breaker, achieving seamless one-click replacement of intelligent circuit breaker parameters.

[0079] For example, if the circuit breaker parameters of the previous circuit breaker are not found in the Redis cache database, the corresponding circuit breaker parameters are then queried in the MySQL relational database using the device identifier of the previous circuit breaker. Furthermore, if the circuit breaker parameters of the previous circuit breaker are found in the Redis cache database, the data in the MySQL relational database can be selectively updated while returning the circuit breaker parameters, so that subsequent queries are faster, more accurate, and more efficient.

[0080] It should be noted that this application adopts a query strategy of first querying the Redis cache database, and then querying the MySQL relational database if the query is not found in the Redis cache database. Based on the characteristics of the cache database and the relational database itself, since memory access speed is much faster than disk access, querying through the cache database first can significantly improve the query speed and reduce the number of accesses to the relational database, thereby reducing the load on the relational database and achieving load balancing.

[0081] Based on this, device identifiers are determined through mapping relationships, and circuit breaker parameters are queried based on these identifiers. This efficiently manages the status and parameters of circuit breakers, ensuring accurate tracking and recording of relevant information before and after circuit breaker replacement. Furthermore, a query strategy combining a cached database and a relational database is employed. By first querying the cached database, the number of accesses to the relational database is reduced, thereby alleviating the query burden when retrieving circuit breaker parameters from the database based on the device identifier and improving the efficiency of circuit breaker parameter retrieval.

[0082] Based on the same inventive concept, this application also provides a circuit breaker parameter setting device corresponding to the circuit breaker parameter setting method. Since the principle of the circuit breaker parameter setting device in this application is similar to the circuit breaker parameter setting method described above, the implementation of the circuit breaker parameter setting device can refer to the implementation of the circuit breaker parameter setting method, and the repeated parts will not be described again.

[0083] Reference Figure 6 The diagram shown is a structural schematic of a circuit breaker parameter setting device provided in an embodiment of this application. The circuit breaker parameter setting device 600 includes: a determining module 601 and a processing module 602, wherein:

[0084] The determination module 601 is used to determine whether the circuit breaker deployed at the installation location has been replaced based on the circuit breaker monitoring information. The circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker, and the equipment identifier is used to indicate the equipment information when the circuit breaker is connected to the network.

[0085] The processing module 602 is used to, if the circuit breaker deployed at the installation location is replaced, obtain the circuit breaker parameters of the circuit breaker before replacement deployed at the installation location according to the pre-built mapping relationship and the location identifier corresponding to the installation location, and send the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement deployed at the installation location, so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement. The mapping relationship is used to indicate the association between the location identifier, the device identifier and the circuit breaker parameters.

[0086] Based on this, the circuit breaker parameter setting device according to the embodiment of this application monitors and collects circuit breaker monitoring information in real time through a cloud platform to determine whether the circuit breaker deployed at the installation location has been replaced. If the circuit breaker has been replaced, the device queries the database for the circuit breaker parameters of the circuit breaker before replacement based on the pre-built mapping relationship and the location identifier corresponding to the installation location. The device then sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement through the server, so that the circuit breaker after replacement sets its circuit breaker parameters to those of the circuit breaker before replacement. In this way, the device directly sends the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement through the server, realizing one-click setting of the parameters of the circuit breaker after replacement. During this process, no professional technicians are required to set the parameters of the smart circuit breaker. When the cloud platform detects that the circuit breaker has been replaced, it automatically queries the database to retrieve the circuit breaker parameters of the circuit breaker before replacement and sends these parameters to the replaced circuit breaker via the server. In other words, the parameter setting after the circuit breaker is replaced is automatically completed by the cloud platform without manual intervention, which effectively improves the efficiency of parameter setting when the circuit breaker is replaced.

[0087] In one possible implementation, the determining module 601 is further configured to:

[0088] Based on the circuit breaker's equipment information and server information, generate a device identifier;

[0089] A location identifier is generated based on the circuit breaker's installation location information and server information;

[0090] A mapping relationship is constructed based on the device identifier, location identifier, and the circuit breaker parameters corresponding to the device identifier.

[0091] In one possible implementation, the determining module 601 is further configured to:

[0092] The device information and server information are hashed using a preset hash algorithm to generate a hash value of a first preset length.

[0093] Select a hash value of a first fixed length from the hash values ​​of a first preset length, and use the hash value of the first fixed length as the first device code;

[0094] Based on the snowflake algorithm, the first device code, the second preset length timestamp, and the third preset length serial number are combined according to a preset format to generate a device identifier, wherein the sum of the lengths of the first device code, the timestamp, and the serial number satisfies the preset length value.

[0095] In one possible implementation, the determining module 601 is further configured to:

[0096] The installation location information and server information are hashed using a preset hash algorithm to generate a hash value of a fourth preset length.

[0097] Select a hash value of a second fixed length from the hash values ​​of the fourth preset length, and use the hash value of the second fixed length as the second device code;

[0098] Based on the snowflake algorithm, the second device code, the fifth preset length timestamp, and the sixth preset length serial number are combined according to a preset format to generate a location identifier.

[0099] In one possible implementation, the processing module 602 is specifically used for:

[0100] Based on the mapping relationship and the location identifier corresponding to the installation location, determine the equipment identifier of the circuit breaker before replacement;

[0101] Based on the equipment identifier of the circuit breaker before replacement, query the circuit breaker parameters of the circuit breaker before replacement from the preset database, which includes a cache database and a relational database.

[0102] In one possible implementation, the processing module 602 is specifically used for:

[0103] Based on the device identifier of the circuit breaker before replacement, query the circuit breaker parameters of the circuit breaker before replacement from the cache database;

[0104] If the circuit breaker parameters of the previous circuit breaker are not found in the cache database, then the circuit breaker parameters of the previous circuit breaker are retrieved from the relational database.

[0105] In one possible implementation, the determining module 601 is specifically used for:

[0106] The device identifiers of the circuit breakers deployed at the installation location are polled at preset intervals to obtain the device identifiers corresponding to the current query time and the device identifiers corresponding to the next query time.

[0107] If the first correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the current query time is inconsistent with the second correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the next query time, then it is determined that the circuit breaker deployed at the installation location has been replaced.

[0108] The processing flow of each module in the device and the interaction flow between each module can be referred to the relevant descriptions in the above method embodiments, and will not be detailed here.

[0109] This application also provides an electronic device 700, such as... Figure 7The diagram shown is a schematic representation of the structure of an electronic device 700 provided in an embodiment of this application. It includes a processor 701 and a memory 702, and optionally, a bus 703. The memory 702 stores machine-readable instructions executable by the processor 701. When the electronic device 700 is running, the processor 701 and the memory 702 communicate via the bus 703. When the machine-readable instructions are executed by the processor 701, the steps of the circuit breaker parameter setting method described in any of the preceding claims are performed.

[0110] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, performs the steps of the circuit breaker parameter setting method as described in any of the preceding claims.

[0111] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems and devices described above can be referred to the corresponding processes in the method embodiments, and will not be repeated here. In the several embodiments provided in this application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. Furthermore, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed mutual coupling or direct coupling or communication connection can be through some communication interfaces; the indirect coupling or communication connection of devices or modules can be electrical, mechanical, or other forms.

[0112] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. If the functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0113] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.

Claims

1. A method for setting circuit breaker parameters, characterized in that, include: Based on the circuit breaker monitoring information, it is determined whether the circuit breaker deployed at the installation location has been replaced. The circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker. The equipment identifier is used to indicate the equipment information when the circuit breaker is connected to the network. If the circuit breaker deployed at the installation location is replaced, the circuit breaker parameters of the previous circuit breaker deployed at the installation location are obtained according to the pre-built mapping relationship and the location identifier corresponding to the installation location. The circuit breaker parameters of the previous circuit breaker are then sent to the replaced circuit breaker deployed at the installation location, so that the replaced circuit breaker sets its circuit breaker parameters to those of the previous circuit breaker. The mapping relationship is used to indicate the association between the location identifier, the device identifier, and the circuit breaker parameters corresponding to the device identifier.

2. The circuit breaker parameter setting method according to claim 1, characterized in that, Before obtaining the circuit breaker parameters of the pre-replacement circuit breaker deployed at the installation location based on the pre-built mapping relationship and the location identifier corresponding to the installation location, the method further includes: The device identifier is generated based on the circuit breaker's device information and server information; The location identifier is generated based on the installation location information of the circuit breaker and the server information; The mapping relationship is constructed based on the device identifier, the location identifier, and the circuit breaker parameters corresponding to the device identifier.

3. The circuit breaker parameter setting method according to claim 2, characterized in that, The step of generating the device identifier based on the circuit breaker's device information and server information includes: The device information and the server information are hashed using a preset hash algorithm to generate a hash value of a first preset length; Select a hash value of a first fixed length from the hash values ​​of the first preset length, and use the hash value of the first fixed length as the first device code; Based on the snowflake algorithm, the first device code, the second preset length timestamp, and the third preset length serial number are combined according to a preset format to generate the device identifier, wherein the sum of the lengths of the first device code, the timestamp, and the serial number satisfies the preset length value.

4. The circuit breaker parameter setting method according to claim 2, characterized in that, Based on the installation location information of the circuit breaker and the server information, the location identifier is generated, including: The installation location information and the server information are hashed using a preset hash algorithm to generate a hash value of a fourth preset length. Select a hash value of a second fixed length from the hash values ​​of the fourth preset length, and use the hash value of the second fixed length as the second device code; Based on the snowflake algorithm, the second device code, the fifth preset length timestamp, and the sixth preset length serial number are combined according to a preset format to generate the location identifier.

5. The circuit breaker parameter setting method according to claim 1, characterized in that, The step of obtaining the circuit breaker parameters of the pre-replaced circuit breaker deployed at the installation location based on the pre-built mapping relationship and the location identifier corresponding to the installation location includes: Based on the mapping relationship and the location identifier corresponding to the installation location, determine the device identifier of the circuit breaker before replacement; Based on the device identifier of the circuit breaker before replacement, the circuit breaker parameters of the circuit breaker before replacement are queried from a preset database, which includes a cache database and a relational database.

6. The circuit breaker parameter setting method according to claim 5, characterized in that, The step of querying the circuit breaker parameters of the previous circuit breaker from a preset database based on the device identifier of the previous circuit breaker includes: Based on the device identifier of the circuit breaker before replacement, query the circuit breaker parameters of the circuit breaker before replacement from the cache database; If the circuit breaker parameters of the circuit breaker before replacement are not found in the cache database, then the circuit breaker parameters of the circuit breaker before replacement are retrieved from the relational database.

7. The circuit breaker parameter setting method according to claim 1, characterized in that, The step of determining whether the circuit breaker deployed at the installation location has been replaced based on circuit breaker monitoring information includes: The device identifiers of the circuit breakers deployed at the installation location are polled at preset intervals to obtain the device identifiers corresponding to the current query time and the device identifiers corresponding to the next query time. If the first correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the current query time is inconsistent with the second correspondence between the location identifier corresponding to the installation location and the device identifier corresponding to the next query time, then it is determined that the circuit breaker deployed at the installation location has been replaced.

8. A circuit breaker parameter setting device, characterized in that, include: The determination module is used to determine whether the circuit breaker deployed at the installation location has been replaced based on the circuit breaker monitoring information. The circuit breaker monitoring information is used to indicate the correspondence between the location identifier and the equipment identifier corresponding to the installation location. The location identifier is used to indicate the installation location information of the circuit breaker, and the equipment identifier is used to indicate the equipment information when the circuit breaker was connected to the network. The processing module is configured to, if the circuit breaker deployed at the installation location is replaced, obtain the circuit breaker parameters of the circuit breaker before replacement deployed at the installation location based on a pre-built mapping relationship and the location identifier corresponding to the installation location, and send the circuit breaker parameters of the circuit breaker before replacement to the circuit breaker after replacement deployed at the installation location, so that the circuit breaker after replacement sets the circuit breaker parameters to the circuit breaker parameters of the circuit breaker before replacement, wherein the mapping relationship is used to indicate the association between the location identifier, the device identifier, and the circuit breaker parameters.

9. An electronic device, characterized in that, include: The electronic device includes a processor and a memory, the memory storing machine-readable instructions executable by the processor, which, when the electronic device is in operation, are executed by the processor to perform the steps of the circuit breaker parameter setting method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the circuit breaker parameter setting method as described in any one of claims 1 to 7.