Circuit breaker address automatic assignment device and method based on voltage detection

By using a voltage-sensing-based circuit breaker address automatic allocation device, which utilizes an internal pull-up resistor and an external encoding resistor to form a closed-loop voltage divider circuit, and combines it with a microcontroller unit for analog-to-digital conversion and feature analysis, the device solves the problems of cumbersome circuit breaker address allocation operation, low reliability, and high cost. It achieves efficient and reliable automatic address allocation and is suitable for power distribution systems of different sizes.

CN122120245APending Publication Date: 2026-05-29ZHEJIANG ZHONGYIHAO TECH
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG ZHONGYIHAO TECH
Filing Date
2026-03-03
Publication Date
2026-05-29

Smart Images

  • Figure CN122120245A_ABST
    Figure CN122120245A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of intelligent power distribution and electrical control, in particular to a circuit breaker address automatic allocation device and method based on voltage detection. The device comprises an internal pull-up resistor, a voltage detection point, a connection terminal and a micro control unit, a unique resistance coding resistor is arranged at a corresponding position of an external mounting base, and the two constitute a voltage division circuit. The method is characterized in that, through power-on initialization and multiple voltage sampling and filtering, characteristic quantities are calculated based on voltage division, a unique address is matched in combination with a pre-stored mapping table, and after conflict detection, the address is stored and registered. The application adopts passive resistance voltage division and voltage bit characteristic quantity design, cooperates with an anti-interference mechanism, offsets the influence of resistance tolerance and power supply fluctuation, does not need manual operation and complex modules, supports hot plug, has simple structure, low cost, fast and accurate address allocation, is suitable for multi-scale power distribution scenes, has strong stability, and is convenient for batch deployment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent power distribution and electrical control technology, specifically to a circuit breaker address automatic allocation device and method based on voltage detection. Background Technology

[0002] With the rapid development of smart power distribution technology, circuit breakers are increasingly widely used in industrial control, data centers, commercial buildings, and residential power distribution. Their hot-swappable and easy-to-maintain characteristics significantly improve the operation and maintenance efficiency of power distribution systems. The core prerequisite for achieving centralized monitoring, data exchange, and command issuance of multiple circuit breakers is assigning a unique communication address to each device to ensure the accuracy and relevance of bus communication and avoid communication interruptions and command malfunctions caused by address conflicts.

[0003] Current circuit breaker address allocation schemes have not yet formed a mature technology that balances efficiency, reliability, and economy. The three existing mainstream schemes all have insurmountable defects and cannot meet the actual application needs of power distribution systems of different sizes:

[0004] Manual address setting was the mainstream choice for early and some low-end devices, involving manual address configuration via DIP switches, jumper caps, or button combinations on the circuit breaker housing. This method is cumbersome; in scenarios with multiple devices densely deployed, maintenance personnel must verify the configuration against each installation location, easily leading to DIP errors and duplicate addresses. Furthermore, manual setting requires power off, contradicting the hot-swappable maintenance requirements of circuit breakers. When replacing equipment or adjusting addresses, all device addresses must be re-verified, significantly increasing maintenance costs and downtime. Additionally, the added DIP switches and buttons increase the structural complexity of the circuit breaker, reducing its immunity and operational stability in harsh industrial environments such as humidity, dust, and electromagnetic interference.

[0005] The software-automatic address allocation scheme relies on a bus communication protocol for address allocation. The main controller broadcasts instructions, and the circuit breakers report and verify addresses after generating them in the access order or randomly. Although this scheme eliminates manual operation, it is highly dependent on the reliability of bus communication. Strong bus interference during the initial power-on period and signal conflicts when multiple devices respond simultaneously can easily occur, leading to address allocation failures, missed allocations, or duplicate allocations. Some schemes also require the circuit breakers to integrate a unique hardware identifier, necessitating additional storage chips to record the identifier information. This increases hardware costs and prolongs the address allocation process, making it unsuitable for scenarios with stringent response speed requirements.

[0006] Wireless identification solutions such as RFID and NFC integrate tags and readers into circuit breakers and mounting bases respectively to achieve contactless address mapping. While this solution enables automatic allocation, RFID and NFC modules are expensive, resulting in poor economic efficiency for mass deployment. Furthermore, factors such as strong electromagnetic interference, dust accumulation, and equipment vibration in industrial power distribution scenarios can easily lead to wireless signal attenuation and reading failures. The high installation accuracy requirements of tags and readers also increase the difficulty of equipment assembly and base design, making it difficult to adapt to long-term stable operation in harsh industrial environments.

[0007] In the prior art, there are also automatic address allocation schemes for serial bus communication systems. For example, the prior art document with patent number CN202411701175.5 discloses a slave node address allocation method and device for LIN networks. The core of this method is a dynamic addressing mechanism based on current sampling and noise suppression. This scheme establishes a complex current sampling unit, integrating analog front-end structures such as switch arrays, multi-stage operational amplifiers, current sources, sampling resistors, and compensation circuits to construct a differential sampling loop to separate the real bus current from the interference current, thereby improving the address allocation accuracy. Essentially, it is an active anti-interference design that focuses on solving the signal integrity problem in serial bus communication. However, this solution has obvious limitations: First, the hardware structure is complex, requiring additional configuration of various active devices and precision components, resulting in high costs and hindering miniaturization and integration, making it unsuitable for the compact internal space of circuit breakers; Second, the technical approach focuses on current signal denoising during dynamic communication, without addressing physical location identification and modular plug-and-play structures, failing to meet the circuit breaker's need for plug-and-play address allocation based on installation location; Third, the logic for converting current values ​​to addresses is not clearly defined, with the core objective of improving acquisition accuracy, which is inconsistent with the circuit breaker's requirements for convenient and low-cost address allocation.

[0008] In addition, some existing improvement solutions attempt to use the principle of resistor voltage division to realize address encoding, but they generally have design flaws: either the resistance value differentiation is insufficient, and the influence of resistance tolerance and power supply fluctuation in mass production is not considered, resulting in low address recognition accuracy and frequent misassignment; or the anti-interference mechanism is not designed, and it is unable to offset the influence of external electromagnetic interference and contact jitter, making it difficult to adapt to the needs of multiple addresses and high-precision allocation, and failing to fundamentally solve the pain points of the existing solutions.

[0009] In summary, there is an urgent need for an automatic circuit breaker address allocation technology that is simple in structure, low in cost, strong in anti-interference capability, and adaptable to hot-swapping and mass deployment. This technology would address the problems of existing solutions, such as cumbersome operation, low reliability, high cost, poor environmental adaptability, and the complex structure and insufficient scenario adaptability of comparative solutions. The goal would be to achieve address allocation immediately upon power-on after the circuit breaker is inserted into the base, balancing allocation accuracy, speed, and long-term stability, and adapting to the application needs of power distribution systems of different scales. Summary of the Invention

[0010] The purpose of this invention is to provide an automatic address allocation device and method for circuit breakers based on voltage detection, so as to solve the problems of cumbersome operation, low reliability, high cost and insufficient adaptability of existing address allocation schemes mentioned in the background art.

[0011] To achieve the above objectives, the present invention provides the following technical solution:

[0012] A circuit breaker address automatic allocation device based on voltage detection, applied inside a smart circuit breaker with communication capabilities, includes:

[0013] An internal pull-up resistor, one end of which is connected to the power supply of the microcontroller unit inside the intelligent circuit breaker;

[0014] The voltage detection point is connected to the other end of the internal pull-up resistor;

[0015] The first connection terminal is electrically connected to the voltage detection point and is used to lead out to the outside of the smart circuit breaker;

[0016] The second connection terminal is electrically connected to the internal system ground of the intelligent circuit breaker and is used to lead out to the outside of the intelligent circuit breaker.

[0017] A microcontroller unit, whose input pin with analog-to-digital conversion function is connected to the voltage detection point;

[0018] When the intelligent circuit breaker is connected to an external mounting base via the first and second connection terminals, the mounting base has an externally encoded resistor with a unique resistance value connected between the first and second connection terminals at corresponding positions. The internal pull-up resistor, the externally encoded resistor, and the internal system ground form a closed-loop voltage divider circuit. The microcontroller unit is configured as follows:

[0019] After power-on, the voltage value at the voltage detection point is detected via the analog-to-digital converter pin. The voltage value satisfies the formula:

[0020] ;in, Provide the power supply voltage for the microcontroller unit. This refers to the internal pull-up resistor value. The resistance value is the external encoder resistor.

[0021] Based on the voltage value Parse and The relevant features, combined with the pre-stored feature-address mapping table, are used to assign a unique communication address to themselves.

[0022] Preferably, the first and second connection terminals are dedicated pins of the pluggable gold finger interface of the intelligent circuit breaker. The gold finger pins are gold-plated and the pin contact resistance is no more than 50mΩ. A 100pF to 10nF filter capacitor is connected in series between the first connection terminal and the voltage detection point to suppress high-frequency noise interference.

[0023] Preferably, the internal pull-up resistor is a metal film resistor with an accuracy of not less than 1% and a temperature drift coefficient of not more than 50ppm / ℃, and the resistance value range is 5kΩ to 20kΩ; the power supply of the microcontroller is a linear regulated power supply with a voltage fluctuation range of not more than ±5%, ensuring that the voltage ratio consistency error detected by mass-produced smart circuit breakers under the same external coded resistor does not exceed ±2%.

[0024] Preferably, the characteristic quantity resolved by the microcontroller is the ratio of the voltage at the voltage detection point to the power supply voltage of the microcontroller. The feature-address mapping table is a voltage ratio-address mapping table, and the voltage ratio range is divided in the following way: For N communication addresses, the voltage ratio range is... The system is divided into N non-overlapping continuous intervals. The width of each interval is determined based on the tolerance of the external encoding resistor, the power supply fluctuation range, and the ADC sampling error. The difference in the isolation band voltage ratio between adjacent intervals is not less than 0.02.

[0025] Preferably, the external coded resistor is selected from the E24 series precision metal film resistor, with an accuracy of not less than 1% and a resistance range of 1kΩ to 174kΩ. The resistance values ​​of the external coded resistors corresponding to different installation positions meet the following conditions: any two resistance values and Corresponding voltage ratio difference This ensures that the ADC sampling can reliably distinguish the feature quantities corresponding to different addresses.

[0026] Preferably, the device is electrically connected to the external circuit only through a voltage divider circuit consisting of the first and second connection terminals, without any other ground connection, power supply connection or signal connection. Furthermore, the external encoding resistor is a passive device, which does not introduce any external active power supply, thereby achieving complete electrical isolation between the address detection circuit and the external circuit and preventing external interference from being conducted to the internal control system of the intelligent circuit breaker.

[0027] Preferably, there are at least two smart circuit breakers. The external mounting base is provided with terminal blocks that correspond one-to-one with the installation position of each smart circuit breaker. The pins of the terminal blocks adopt a spring-type clamping structure to ensure reliable contact with the gold fingers of the smart circuit breaker. Each terminal block has an externally encoded resistor with a unique resistance value fixed between the corresponding pins by welding. The welded joint of the resistor is treated with insulation encapsulation.

[0028] When the smart circuit breaker is inserted into the corresponding installation position, its first connection terminal and second connection terminal are electrically connected to the corresponding pins of the terminal block, so that the internal pull-up resistor of the smart circuit breaker and the external encoding resistor at the corresponding position form a closed-loop voltage divider circuit. Moreover, the address detection circuits between multiple smart circuit breakers are independent of each other and have no electrical interconnection, realizing automatic parallel address allocation for multiple devices.

[0029] On the other hand, the present invention also provides a method for automatic circuit breaker address allocation based on voltage detection, applied to the above-mentioned automatic circuit breaker address allocation device based on voltage detection, comprising the following steps:

[0030] S1: The intelligent circuit breaker is powered on. The microcontroller initializes the analog-to-digital converter module and related peripherals, and configures the reference voltage of the analog-to-digital converter module as follows: The sampling resolution is no less than 12 bits;

[0031] S2: The microcontroller unit samples the voltage at the voltage detection point at least 16 times continuously via the analog-to-digital conversion pin, and processes the sampled data using a moving average filtering algorithm to obtain a stable voltage value. The window size of the moving average filtering algorithm is 8 to 16 sampling points;

[0032] S3: Based on the stable voltage value The characteristic quantity associated with the external encoding resistor is calculated using the following formula:

[0033] ;in, The calculated resistance value for the externally encoded resistor. This refers to the internal pull-up resistor value. Provide the power supply voltage for the microcontroller unit;

[0034] S4: Query the "feature quantity-address" mapping table pre-stored in the non-volatile memory of the microcontroller unit. Each unique feature quantity interval in the mapping table corresponds to a unique communication address. An isolation band of no less than 5% is reserved at the interval boundary to determine the interval to which the feature quantity belongs and the corresponding communication address.

[0035] S5: Write the determined communication address into the EEPROM or Flash memory of the microcontroller, overwriting the original address data, and embed the address into the address field of the subsequent bus communication frame;

[0036] S6: Address allocation is complete. The intelligent circuit breaker sends an address registration message to the main controller and then enters normal operation.

[0037] Preferably, the implementation process of the moving average filtering algorithm in step S2 is as follows: M consecutively collected sample values ​​are stored in a buffer array, the maximum and minimum values ​​in the array are discarded, and the arithmetic mean of the remaining M-2 values ​​is calculated as the stable voltage value of this sample. The value of M is 16 to 32, ensuring that the signal-to-noise ratio of the filtered data is not less than 60dB.

[0038] Preferably, step S4 also includes an address conflict detection step: after determining the communication address, the microcontroller sends an address verification request to the main controller via the bus, and the main controller responds to whether the address has been occupied by other devices; if the address is not occupied, step S5 is executed; if the address is occupied, the microcontroller re-executes steps S2 to S4, and if an address conflict occurs in 3 consecutive detections, a preset default address is allocated, and an address conflict alarm message is sent via the bus. The default address is a dedicated address that is not included in the feature-address mapping table.

[0039] Compared with the prior art, the beneficial effects of the present invention are:

[0040] 1. This invention significantly improves the efficiency and adaptability of circuit breaker address allocation, completely solving the pain points of cumbersome operation and poor adaptability of traditional solutions. Compared to manual address setting, it eliminates the need for maintenance personnel to configure DIP switches, jumpers, or buttons one by one. Address allocation is automatically completed after the circuit breaker is inserted into the mounting base and powered on. The entire process is quick and supports hot-swappable maintenance. No power-off verification is required when replacing equipment or adjusting addresses, greatly reducing maintenance workload and the probability of human error. Furthermore, the address allocation process does not rely on bus communication timing or external active devices, making it adaptable to small, medium, and large-scale power distribution systems. Whether it's a small number of devices in a home power distribution system or a densely deployed data center, it can quickly respond to address allocation needs, demonstrating exceptional flexibility and versatility.

[0041] 2. This invention effectively enhances the reliability and anti-interference capability of address allocation, ensuring stable operation in harsh industrial environments. An address encoding loop is constructed through a passive resistor voltage divider detection mechanism. The external encoding resistor and the internal pull-up resistor form a closed-loop voltage divider. Combined with an RC low-pass filter circuit, an improved moving average filtering algorithm, and voltage ratio characteristic design, it effectively offsets the effects of resistance tolerance, power supply fluctuations, high-frequency electromagnetic interference, and contact jitter. An isolation band is reserved between characteristic intervals corresponding to adjacent addresses. Combined with dual characteristic verification and address conflict detection processes, address confusion, misallocation, and conflicts are eliminated. Detection errors are controllable over a wide temperature range. Even in complex industrial environments with strong electromagnetic interference, dust, and vibration, it maintains extremely high address recognition accuracy, with stability far exceeding that of wireless identification and pure software allocation schemes.

[0042] 3. This invention simplifies structural design, controls production costs, and facilitates mass production and large-scale deployment. The device constructs its core circuit using only internal pull-up resistors, filter capacitors, and external encoding resistors, eliminating the need for integrated components such as DIP switches, RFID modules, and additional storage chips. Its simple structure and compact size allow for direct integration into circuit breakers, reducing hardware costs and assembly complexity. Standardized precision metal film resistors are used for the external encoding resistors, ensuring convenient and low-cost procurement. The internal circuit relies on the MCU's built-in ADC and Flash resources, eliminating the need for additional peripherals and further reducing costs. During mass production, unified parameter selection and pre-stored mapping tables ensure consistent detection across devices, adapting to the large-scale deployment needs of power distribution systems and combining economic efficiency with practicality. Attached Figure Description

[0043] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are explained in detail together with the embodiments of the invention, but do not constitute a limitation thereof.

[0044] Figure 1 This is a diagram illustrating the address allocation logic of the intelligent device according to the present invention.

[0045] Figure 2 This is a block diagram of the automatic address allocation device for circuit breakers based on voltage detection according to the present invention;

[0046] Figure 3 This is a flowchart illustrating the automatic address allocation method for circuit breakers based on voltage detection according to the present invention. Detailed Implementation

[0047] The technical solutions of the present invention will be clearly and completely described below with reference to the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0048] This voltage-sensing-based automatic address allocation device for circuit breakers is integrated inside the smart circuit breaker. It works in conjunction with an external mounting base to achieve automatic address allocation. Its core relies on a passive resistor voltage divider circuit and an analog-to-digital converter detection mechanism. The selection, connection relationships, and functional implementation of each component are all designed around detection accuracy, anti-interference capability, batch compatibility, and electrical safety, as detailed below:

[0049] Internal pull-up resistor: A 10kΩ metal film resistor with 1% accuracy and a temperature drift coefficient of 30ppm / ℃ is selected. This resistance value ensures that the voltage divider is within the effective detection range of the analog-to-digital converter (ADC) module, while controlling the loop current to the hundreds of microamps, reducing power consumption. One end of the resistor is directly soldered to the power supply terminal of the microcontroller unit (MCU), and the other end serves as a voltage detection point. The high precision of the metal film material ensures consistent resistance values ​​during mass production, and the low temperature drift coefficient effectively reduces detection deviations within the wide industrial temperature range of -40℃ to 85℃.

[0050] Voltage detection circuit: A 1nF ceramic filter capacitor is connected in series at the voltage detection point. One end of the capacitor is connected to the detection point, and the other end is connected to the internal system ground, forming an RC low-pass filter circuit with a cutoff frequency of approximately 15.9kHz. This suppresses high-frequency interference from power grid harmonics and external electromagnetic radiation, preventing distortion of the sampling signal. The first and second connection terminals use pluggable gold finger pins with a gold plating thickness of not less than 0.1μm and a pin contact resistance controlled within 30mΩ. Reducing the contact resistance lowers the voltage division error. The pins are integrated into the gold finger interface at the bottom of the circuit breaker housing, precisely corresponding to the terminal block position of the external mounting base. Combined with the spring-loaded clamping structure of the base, reliable contact is ensured after plugging and unplugging, with no instantaneous circuit breakage.

[0051] Microcontroller Unit: Utilizing the STM32L431RCT6 chip, it features low power consumption, high stability, and industrial-grade anti-interference capabilities. It integrates a 12-bit ADC module with a sampling rate up to 500kHz, meeting the requirements for rapid address allocation, with a total process time ≤50ms. The ADC input pin PA0 is directly connected to the voltage detection point. The chip is powered by an AMS1117 linear voltage regulator outputting -3.3V, maintaining a stable voltage of 3.3V±5%, providing a stable reference for voltage divider calculations. It incorporates 64KB of on-chip Flash memory for pre-storing the feature-address mapping table and storing the final allocated communication address, eliminating the need for additional memory expansion, simplifying the device structure and reducing costs. The chip also integrates an I2C / SPI bus interface for subsequent address verification, registration, and data interaction.

[0052] External encoding resistors: Integrated between the terminal blocks of the external mounting base, fixed by reflow soldering and epoxy-insulated to prevent short circuits, oxidation, or poor contact during installation and maintenance. The resistors are E24 series 1% precision metal film resistors, with a unique resistance value for each mounting position, ranging from 1kΩ to 174kΩ. The voltage difference between adjacent resistance values ​​is not less than 0.03, ensuring the ADC module can reliably distinguish the characteristic quantities corresponding to different addresses and preventing address confusion. Furthermore, these resistors are passive devices, requiring no external power supply, thus completely electrically isolating the address detection circuit from external circuits and preventing external voltage fluctuations from being transmitted to the circuit breaker's internal control system.

[0053] The voltage divider detection principle works as follows: When the circuit breaker is inserted into the external mounting base, the internal pull-up resistor, the external encoding resistor, and the internal system ground form a closed-loop voltage divider circuit, establishing a stable voltage divider relationship. After the MCU is powered on, it detects the voltage value at the voltage detection point in real time through the ADC pin. The pressure distribution relationship satisfies the following formula:

[0054] ;in, The power supply voltage for the MCU is 3.3V. The internal pull-up resistor has a resistance of 10kΩ. This is the resistance value of the externally encoded resistor. Because... and Given a fixed value, obtained through detection Reverse calculation and Relevant characteristic quantities. To compensate for the impact of power supply voltage fluctuations on the detection results, in practical applications, a voltage ratio k= is preferred. / As a core feature, it decouples the address allocation logic from the absolute voltage fluctuation of the power supply, significantly improving detection stability.

[0055] This voltage-detection-based automatic circuit breaker address allocation method is executed using the aforementioned device. Through a complete process of system initialization, voltage sampling and filtering, feature calculation, address matching, and storage registration, it achieves automatic circuit breaker address allocation, balancing allocation speed and reliability. The specific operations, parameter settings, and logic design for each step are as follows:

[0056] Step 1: After the intelligent circuit breaker is powered on, the MCU immediately executes the initialization program. The core configuration includes: configuring the ADC module reference voltage to the MCU supply voltage of 3.3V, setting the sampling resolution to 12 bits, the quantization range to 0~4095, and the sampling clock frequency to 1MHz to balance the sampling rate and accuracy; initializing the bus interface, which defaults to I2C but is compatible with SPI, and configuring the communication baud rate to 100kHz for address verification and registration communication with the main controller; initializing the on-chip Flash memory, clearing the previous address cache data (sector 0x08001000) to avoid interference from historical addresses, and verifying the integrity of the feature quantity-address mapping table. If the table data is corrupted, a fault flag is triggered, awaiting maintenance intervention.

[0057] Step 2: The MCU continuously samples the voltage detection point through the ADC input pin PA0. The number of samplings is dynamically adjusted according to the scenario requirements, ranging from 16 to 32 times. The sampled data is stored in a 16-bit buffer array. To suppress sampling fluctuations caused by random noise, electromagnetic interference, and contact jitter, an improved moving average filtering algorithm is adopted: discarding the maximum and minimum values ​​in the array, and calculating the arithmetic mean of the remaining valid sampled values ​​to obtain a stable voltage value V_ad. This filtering method can improve the data signal-to-noise ratio to over 65dB, effectively filtering out high-frequency interference and instantaneous fluctuations, ensuring the reliability of the sampled data.

[0058] Step 3: Based on the stable voltage value V_ad, simultaneously calculate two characteristic quantities: the calculated resistance value of the external encoding resistor and the voltage ratio. Using these two characteristic quantities for verification reduces errors and improves address matching accuracy. Specifically, the calculated resistance value of the external encoding resistor... The calculation formula is as follows:

[0059] Substitute the known parameters, =3.3V, =10kΩ, can be directly passed through Estimation Simultaneously calculate the voltage ratio k= / 3.3V serves as the core basis for address matching. Dual feature cross-verification effectively offsets the effects of resistance tolerance (±1%), power supply fluctuations (±5%), and ADC sampling errors (±0.5LSB), ensuring feature accuracy.

[0060] Step 4: The MCU reads the pre-stored voltage ratio-address mapping table in the on-chip Flash memory. This mapping table divides the voltage ratio range (0,1) into several non-overlapping continuous intervals, with a voltage ratio isolation band of 0.02 to 0.03 reserved between adjacent intervals to compensate for detection deviations caused by various errors. After determining the interval to which the calculated voltage ratio belongs, the MCU obtains the corresponding unique communication address.

[0061] To avoid address conflicts when multiple circuit breakers are connected simultaneously, a conflict detection process is executed after address matching: The MCU sends an address verification request message to the main controller via the bus, containing the device identifier and candidate address. The main controller queries the list of registered addresses and returns the verification result. If the address is not occupied, the subsequent address storage step is performed; if the address is occupied, the MCU re-executes the voltage sampling, filtering, and characteristic quantity calculation process. If address conflicts occur in three consecutive detections, a preset default address or a dedicated abnormal address, such as 0xFF, is automatically assigned, and an address conflict alarm message is sent to the main controller to facilitate troubleshooting by maintenance personnel, such as mismatched base resistors or multiple devices mistakenly plugged into the same position.

[0062] Step 5: Write the successfully matched and conflict-free communication address to the designated sector (address 0x08001000) of the on-chip Flash memory, overwriting the original data. The non-volatile nature of the Flash memory ensures that the address is not lost after the circuit breaker is powered off, and no reallocation is required upon power-up. Subsequently, the MCU embeds this address into the address field (occupying 1 byte) of the bus communication frame and sends an address registration message to the main controller. The message contains the device model, assigned address, characteristic detection value, and accuracy information. After receiving and confirming the message, the main controller sends a registration success command to the circuit breaker. The circuit breaker completes address registration, enters normal operation, and participates in bus data interaction and command response.

[0063] Example 1: 24-way address allocation

[0064] This device employs a single-channel analog-to-digital converter (ADC) pin encoding scheme, achieving precise allocation of 24 independent hardware addresses from 1 to 24 by measuring the resistance value of an external precision configuration resistor. This scheme ensures address uniqueness while minimizing hardware design complexity and the number of peripheral components, making it suitable for medium to large-scale power distribution scenarios with high requirements for hardware integration and cost control, balancing accuracy and simplicity.

[0065] Core parameter configuration: The MCU selected is STM32L431RCT6, with a stable supply voltage of 3.3V±5%. Voltage sampling is completed only through a single ADC pin (PA0), without the need for additional ADC channels. The internal pull-up resistor is a 6.8kΩ metal film resistor with 1% accuracy and 30ppm / ℃ temperature drift, which is suitable for voltage division detection of external encoded resistors with a wide resistance range and controls the power consumption of the control loop. The ADC module adopts 12-bit resolution, and the detection accuracy is improved by using oversampling technology. The sampling number is 32 times, and a moving average + median value composite filtering algorithm is used to suppress high-frequency interference and contact jitter. The voltage ratio isolation band is set to 0.025. The communication address range is 1~24, and the bus interface adopts SPI to adapt to the anti-interference requirements of medium and large systems.

[0066] External coding resistor selection: E96 series 0.5% high-precision metal film resistors are selected, with resistance values ​​covering 0.91kΩ to 180kΩ. 24 unique resistance values ​​are carefully chosen to ensure that the voltage ratio difference between any two resistance values ​​is ≥0.025, completely offsetting the effects of resistor tolerances, power supply fluctuations, and ADC sampling errors, and avoiding address confusion. The resistors are fixed to the external mounting base terminal blocks via reflow soldering and are epoxy-insulated to improve operational stability in harsh environments.

[0067] External encoding resistor value Voltage ratio k range Corresponding communication address Grouped by region 0.91kΩ 0.119~0.144 1 First District 22kΩ 0.763~0.788 12 Second Zone 110kΩ 0.943~0.968 23 Third District 180kΩ 0.968~0.993 24 Third District

[0068] Operational Results: The single-channel ADC pin design significantly simplifies the hardware circuitry, reduces the space occupied by external components, and lowers hardware costs by more than 30% compared to multi-channel solutions. It also adapts to the compact internal installation environment of circuit breakers. When 24 circuit breakers are connected in parallel across different areas, the address allocation accuracy reaches 100%, with a single device allocation time of ≤45ms. After power failure, the address is permanently stored in the on-chip Flash memory, eliminating the need for reassignment upon power-up. In a wide temperature range of -40℃ to 85℃ and under strong electromagnetic interference conditions, the voltage ratio detection error is ≤±0.8%. Continuous operation is free of address anomalies and misallocation issues. Hot-swappable maintenance is supported, fully adapting to the batch deployment and efficient operation and maintenance needs of medium to large-scale power distribution systems.

[0069] Example 2: 8-way address allocation (suitable for small power distribution systems)

[0070] This embodiment is designed for scenarios such as home power distribution and small computer rooms, and is adapted to the address allocation requirements of 8 circuit breakers. The core pursuits are simple structure, controllable cost, and high reliability. The specific parameter settings and operating results are as follows:

[0071] Core parameter configuration: MCU power supply voltage 3.3V, internal pull-up resistor value 10kΩ, ADC sampling times 24 times, 22 valid sample values ​​retained after filtering, voltage ratio isolation band 0.02, communication address range 0x01~0x08, bus interface adopts I2C.

[0072] External encoding resistor selection: For the eight communication addresses, E24 series 1% precision metal film resistors are selected, with resistance values ​​of 1.2kΩ, 1.8kΩ, 2.7kΩ, 4.3kΩ, 6.8kΩ, 10kΩ, 15kΩ, and 22kΩ. The voltage ratio range and communication address corresponding to each resistance value are shown in the table below:

[0073] External encoding resistor value Voltage ratio k range Corresponding communication address 1.2kΩ 0.105~0.125 0x01 1.8kΩ 0.153~0.173 0x02 2.7kΩ 0.211~0.231 0x03 4.3kΩ 0.298~0.318 0x04 6.8kΩ 0.405~0.425 0x05 10kΩ 0.500~0.520 0x06 15kΩ 0.600~0.620 0x07 22kΩ 0.680~0.700 0x08

[0074] Operational Results: After the circuit breaker is inserted into the base, the address allocation process is completed within 30ms of power-on, with 100% address matching accuracy. Within a wide temperature range of -40℃ to 85℃, the voltage ratio detection error does not exceed ±1.5%, with no address conflicts, misallocations, or loss. Even with ±10% grid voltage fluctuations and external electromagnetic interference (GB / T17626.3 standard), it can still stably complete address allocation, fully adapting to the needs of small power distribution systems. The cost of a single device is controlled within 5 yuan, excluding the MCU.

[0075] Example 3: 16-way address allocation (applicable to medium-sized power distribution systems)

[0076] This embodiment is designed for scenarios such as office buildings and industrial park workshops, adapting to the address allocation requirements of 16 circuit breakers. Optimized parameter configuration enhances address differentiation and anti-interference capabilities, and it is suitable for scenarios with multiple devices accessing in parallel. Specific settings and operational effects are as follows:

[0077] Key parameter configuration: MCU power supply voltage 3.3V, internal pull-up resistor value adjusted to 8.2kΩ, reducing the resistance value to expand the voltage ratio range and improve multi-address differentiation, ADC sampling times 32 times, retaining 30 valid sample values ​​after filtering to further improve sampling stability, voltage ratio isolation band expanded to 0.03 to offset accumulated errors in multi-address scenarios, communication address range 0x01~0x10, bus interface supports I2C / SPI switching.

[0078] External encoder resistor selection: E24 series 1% precision metal film resistors are selected, with resistance values ​​of 1kΩ, 1.5kΩ, 2.2kΩ, 3.3kΩ, 4.7kΩ, 6.8kΩ, 10kΩ, 15kΩ, 22kΩ, 33kΩ, 47kΩ, 68kΩ, 100kΩ, 120kΩ, 150kΩ, and 174kΩ. The voltage ratio range corresponding to each resistance value has been precisely calculated and set to ensure that adjacent ranges do not overlap and the isolation band meets the standards. The parameters corresponding to some key resistance values ​​are shown in the table below:

[0079] External encoding resistor value Voltage ratio k range Corresponding communication address 1kΩ 0.108~0.138 0x01 15kΩ 0.649~0.679 0x08 68kΩ 0.893~0.923 0x0F 174kΩ 0.956~0.986 0x10

[0080] Operational Results: When 16 circuit breakers are connected in parallel, there are no address conflicts, and the address allocation time for a single device is no more than 40ms, meeting the requirements for rapid access of multiple devices. In complex electromagnetic environments (inverter interference in the workshop) and over a wide temperature range, the voltage ratio detection accuracy is controlled within ±1.2%, and the address allocation stability is excellent. The wide resistance range of the external coded resistors adapts to the wiring requirements of different installation locations, and the insulated encapsulation design enhances the safety of the power distribution system. It can operate stably in long-term operation and maintenance scenarios of medium-sized power distribution systems, with a failure rate of less than 0.1% during batch deployment.

[0081] The advantages of the circuit breaker address automatic allocation device and method based on voltage detection proposed in this invention are as follows:

[0082] This invention significantly improves the efficiency and adaptability of circuit breaker address allocation, completely solving the pain points of cumbersome operation and poor adaptability of traditional solutions. Compared to manual address setting, it eliminates the need for maintenance personnel to configure DIP switches, jumpers, or buttons one by one. Address allocation is automatically completed after the circuit breaker is inserted into the mounting base and powered on. The entire process is quick and supports hot-swappable maintenance. No power-off verification is required when replacing equipment or adjusting addresses, greatly reducing maintenance workload and the probability of human error. Furthermore, the address allocation process does not rely on bus communication timing or external active devices, making it adaptable to small, medium, and large-scale power distribution systems. Whether it's a small number of devices in a home power distribution system or a densely deployed data center, it can quickly respond to address allocation needs, demonstrating exceptional flexibility and versatility.

[0083] This invention effectively enhances the reliability and anti-interference capability of address allocation, ensuring stable operation in harsh industrial environments. An address encoding loop is constructed through a passive resistor voltage divider detection mechanism. The external encoding resistor and internal pull-up resistor form a closed-loop voltage divider. Combined with an RC low-pass filter circuit, an improved moving average filtering algorithm, and voltage ratio characteristic design, it effectively offsets the effects of resistance tolerance, power supply fluctuations, high-frequency electromagnetic interference, and contact jitter. An isolation band is reserved between characteristic intervals corresponding to adjacent addresses. Combined with dual characteristic verification and address conflict detection processes, address confusion, misallocation, and conflicts are eliminated. Detection errors are controllable over a wide temperature range. Even in complex industrial environments with strong electromagnetic interference, dust, and vibration, it maintains extremely high address recognition accuracy, with stability far exceeding that of wireless identification and pure software allocation schemes.

[0084] This invention simplifies structural design, controls production costs, and facilitates mass production and large-scale deployment. The device constructs its core circuit using only internal pull-up resistors, filter capacitors, and external encoding resistors, eliminating the need for integrated components such as DIP switches, RFID modules, and additional storage chips. Its simple structure and compact size allow for direct integration into circuit breakers, reducing hardware costs and assembly complexity. Standardized precision metal film resistors are used for the external encoding resistors, ensuring convenient and low-cost procurement. The internal circuit leverages the MCU's built-in ADC and Flash resources, eliminating the need for additional peripherals and further reducing costs. During mass production, unified parameter selection and pre-stored mapping tables ensure consistent detection across devices, adapting to the large-scale deployment requirements of power distribution systems and combining economic efficiency with practicality.

[0085] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely preferred examples and are not intended to limit the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended claims and their equivalents.

Claims

1. A circuit breaker address automatic allocation device based on voltage detection, applied inside a smart circuit breaker with communication function, characterized in that, include: An internal pull-up resistor, one end of which is connected to the power supply of the microcontroller unit inside the intelligent circuit breaker; The voltage detection point is connected to the other end of the internal pull-up resistor; The first connection terminal is electrically connected to the voltage detection point and is used to lead out to the outside of the smart circuit breaker; The second connection terminal is electrically connected to the internal system ground of the intelligent circuit breaker and is used to lead out to the outside of the intelligent circuit breaker. A microcontroller unit, whose input pin with analog-to-digital conversion function is connected to the voltage detection point; When the intelligent circuit breaker is connected to an external mounting base via the first and second connection terminals, the mounting base has an externally encoded resistor with a unique resistance value connected between the first and second connection terminals at corresponding positions. The internal pull-up resistor, the externally encoded resistor, and the internal system ground form a closed-loop voltage divider circuit. The microcontroller unit is configured as follows: After power-on, the voltage value at the voltage detection point is detected via the analog-to-digital converter pin. The voltage value satisfies the formula: ;in, Provide the power supply voltage for the microcontroller unit. This refers to the internal pull-up resistor value. The resistance value is the external encoder resistor. Based on the voltage value Parse and The relevant features, combined with the pre-stored feature-address mapping table, are used to assign a unique communication address to themselves.

2. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The first and second connection terminals are dedicated pins of the pluggable gold finger interface of the intelligent circuit breaker. The gold finger pins are gold-plated and the pin contact resistance is no more than 50mΩ. A 100pF to 10nF filter capacitor is connected in series between the first connection terminal and the voltage detection point to suppress high-frequency noise interference.

3. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The internal pull-up resistor is a metal film resistor with an accuracy of not less than 1% and a temperature drift coefficient of not more than 50ppm / ℃, and the resistance value range is 5kΩ~20kΩ. The microcontroller is powered by a linear regulated power supply with a voltage fluctuation range of no more than ±5%, ensuring that the voltage ratio of mass-produced smart circuit breakers detected under the same external coded resistor has a consistency error of no more than ±2%.

4. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The characteristic quantity analyzed by the microcontroller is the ratio of the voltage at the voltage detection point to the power supply voltage of the microcontroller. The feature-address mapping table is a voltage ratio-address mapping table, and the voltage ratio range is divided in the following way: For N communication addresses, the voltage ratio range is... The system is divided into N non-overlapping continuous intervals. The width of each interval is determined based on the tolerance of the external encoding resistor, the power supply fluctuation range, and the ADC sampling error. The difference in the isolation band voltage ratio between adjacent intervals is not less than 0.

02.

5. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The external coded resistor is selected from the E24 series precision metal film resistor, with an accuracy of not less than 1% and a resistance range of 1kΩ to 174kΩ. The resistance values ​​of the external coded resistors corresponding to different installation positions meet the following condition: any two resistance values... and Corresponding voltage ratio difference This ensures that the ADC sampling can reliably distinguish the feature quantities corresponding to different addresses.

6. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The device is electrically connected to the external circuit only through a voltage divider circuit consisting of the first and second connection terminals. There are no other ground connections, power connections, or signal connections. Furthermore, the external encoding resistor is a passive device and does not introduce any external active power supply, thus achieving complete electrical isolation between the address detection circuit and the external circuit and preventing external interference from being conducted to the internal control system of the intelligent circuit breaker.

7. The circuit breaker address automatic allocation device based on voltage detection according to claim 1, characterized in that, The intelligent circuit breaker is at least two. The external mounting base is provided with terminal blocks that correspond one-to-one with the installation position of each intelligent circuit breaker. The pins of the terminal blocks adopt a spring-type clamping structure to ensure reliable contact with the gold fingers of the intelligent circuit breaker. Each terminal block has an externally encoded resistor with a unique resistance value fixed between the corresponding pins by welding. The welded joint of the resistor is treated with insulation encapsulation. When the smart circuit breaker is inserted into the corresponding installation position, its first connection terminal and second connection terminal are electrically connected to the corresponding pins of the terminal block, so that the internal pull-up resistor of the smart circuit breaker and the external encoding resistor at the corresponding position form a closed-loop voltage divider circuit. Moreover, the address detection circuits between multiple smart circuit breakers are independent of each other and have no electrical interconnection, realizing automatic parallel address allocation for multiple devices.

8. A method for automatically assigning circuit breaker addresses based on voltage detection, applied to the automatic circuit breaker address assignment device based on voltage detection as described in any one of claims 1-7, characterized in that, Includes the following steps: S1: The intelligent circuit breaker is powered on. The microcontroller initializes the analog-to-digital converter module and related peripherals, and configures the reference voltage of the analog-to-digital converter module as follows: The sampling resolution is no less than 12 bits; S2: The microcontroller unit samples the voltage at the voltage detection point at least 16 times continuously via the analog-to-digital conversion pin, and processes the sampled data using a moving average filtering algorithm to obtain a stable voltage value. The window size of the moving average filtering algorithm is 8 to 16 sampling points; S3: Based on the stable voltage value The characteristic quantity associated with the external encoding resistor is calculated using the following formula: ;in, The calculated resistance value for the externally encoded resistor. This refers to the internal pull-up resistor value. Provide the power supply voltage for the microcontroller unit; S4: Query the feature quantity-address mapping table pre-stored in the non-volatile memory of the microcontroller unit. Each unique feature quantity interval in the mapping table corresponds to a unique communication address. An isolation band of no less than 5% is reserved at the interval boundary to determine the interval to which the feature quantity belongs and the corresponding communication address. S5: Write the determined communication address into the EEPROM or Flash memory of the microcontroller, overwriting the original address data, and embed the address into the address field of the subsequent bus communication frame; S6: Address allocation is complete. The intelligent circuit breaker sends an address registration message to the main controller and then enters normal operation.

9. The automatic circuit breaker address allocation method based on voltage detection according to claim 8, characterized in that, The implementation process of the moving average filtering algorithm in step S2 is as follows: M consecutively collected sampled values ​​are stored in a buffer array. After discarding the maximum and minimum values ​​in the array, the arithmetic mean of the remaining M-2 values ​​is calculated as the stable voltage value of this sample. The value of M is 16 to 32, ensuring that the signal-to-noise ratio of the filtered data is not less than 60dB.

10. The automatic circuit breaker address allocation method based on voltage detection according to claim 8, characterized in that, Step S4 also includes an address conflict detection step: After determining the communication address, the microcontroller sends an address verification request to the main controller via the bus. The main controller responds to whether the address has been occupied by other devices. If the address is not occupied, step S5 is executed. If the address is occupied, the microcontroller re-executes steps S2 to S4. If an address conflict occurs in three consecutive detections, a preset default address is allocated, and an address conflict alarm message is sent via the bus. The default address is a dedicated address that is not included in the feature-address mapping table.

Citation Information

Patent Citations

  • Slave node address allocation method and device, readable storage medium, and communication system

    CN119299429B