Method of probing a device at a gateway, gateway and rack

CN122933491APending Publication Date: 2026-10-16SCHNEIDER ELECTRIC (CHINA) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510442634.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-09
Publication Date
2026-10-16

AI Technical Summary

Technical Problem

传统的排查手段只能是在表计上通过手工按键的方式确认配置信息,效率低下

Benefits of technology

[0016]因此,根据本发明实施例,可以根据网关中存储的自学习后的设备表项,针对多个设备创建探测请求,实现对多个设备的一键式探测。此外,还可以探测设备地址是否冲突/重复。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122933491A_ABST
    Figure CN122933491A_ABST
Patent Text Reader

Abstract

A method, a gateway and a power distribution cabinet for detecting devices at the gateway are provided. The method comprises: creating a detection request and sending the detection request to one or more devices based on a self-learned device table item; determining whether a reply packet is received from the device within a predetermined time period; when the reply packet is received, determining whether a data length of the reply packet matches an expected length; and when the data length of the reply packet does not match the expected length, determining that an address of the device is in conflict. Therefore, according to the embodiment of the application, a detection request can be created for multiple devices according to the self-learned device table item stored in the gateway, and one-key detection of the multiple devices is realized. In addition, it is also possible to detect whether the device address is in conflict / repetition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to power distribution systems, and more specifically, to a method for detecting devices at a gateway, a gateway, and a control panel including the gateway. Background Technology

[0002] In the initial stages of operation of a smart power distribution cabinet, after all equipment and communication cables are installed, debugging the communication between the gateway and the various devices connected to the RS-485 bus is an important but tedious task. Besides configuring the gateway parameters, it often requires manually setting the slave address of each device by pressing buttons. For some special devices without an HMI (Human Machine Interface), specialized software is also needed to configure these parameters. Traditional troubleshooting methods rely solely on manually pressing buttons on meters to confirm configuration information, which is inefficient.

[0003] Therefore, a solution is needed that can effectively detect the device. Summary of the Invention

[0004] According to an embodiment of the present invention, a method for probing devices at a gateway is provided, the method comprising: creating a probe request based on a self-learning device table entry and sending the probe request to one or more devices; determining whether a response packet is received from a device within a predetermined time period; when a response packet is received, determining whether the data length of the response packet matches an expected length; and when the data length of the response packet does not match the expected length, determining an address conflict of the device.

[0005] In one example, the method also includes determining whether the device's parameter configuration is incorrect or the cable connection is incorrect when no reply packet is received.

[0006] In one example, the method further includes: determining that the device address is normal when the data length of the response packet matches the expected length; and the mismatch between the data length of the response packet and the expected length includes: the data length of the response packet being greater than the expected length or less than the expected length.

[0007] In one example, creating a probe request based on a self-learning device entry includes: creating a probe request for one or more devices corresponding to an entry in the device entry where the device address is valid.

[0008] In one example, the method further includes: returning the detection results of the one or more devices.

[0009] In one example, the self-learning of the device entry includes: receiving a request from the host computer to read the registers of a device; determining whether the address of the device to be read in the request is included in the device entry; when the address of the device to be read is included in the device entry, determining whether the number of registers to be read in the request is less than the number of registers of the corresponding device in the device entry; when the number of registers to be read is less than the number of registers of the corresponding device in the device entry, updating the register address and register count of the corresponding device in the device entry to the register address and register count of the device included in the request; and setting the unupdated count of the device in the device entry to zero.

[0010] In one example, the method further includes setting the unupdated count of the device in the device table entry to zero when the number of registers to be read is not less than the number of registers of the corresponding device in the device table entry.

[0011] In one example, the method further includes: incrementing the unupdated count of all entries in the device table by 1 when the address of the device to be read is not included in the device table entry; and recording the information of the device to be read in the device table entry.

[0012] In one example, the method further includes: invalidating the device address of a device entry when the number of times an entry in the device table has not been updated reaches a threshold number.

[0013] In one example, the information of the device to be read is recorded in the device table entry in one of the following ways: if there is a blank entry in the device table, the information of the device to be read is recorded in the blank entry as a new device; if there is an entry in the device table with an invalid device address, the information of the device to be read is recorded in the entry with the invalid device address as a new device; and if there are neither blank entries nor invalid device address entries in the device table, the information of the device to be read is recorded in the entry with the maximum number of times it has not been updated as a new device.

[0014] According to another embodiment of the present invention, a gateway in a power distribution system is provided, comprising: a memory; and a processor coupled to the memory and configured to perform the aforementioned method.

[0015] According to another embodiment of the present invention, a power distribution system includes a switchboard cabinet comprising a gateway, the gateway comprising: a memory; and a processor coupled to the memory and configured to perform the aforementioned method.

[0016] Therefore, according to embodiments of the present invention, probe requests can be created for multiple devices based on the self-learned device entries stored in the gateway, enabling one-click detection of multiple devices. Furthermore, it can also detect whether device addresses conflict or are duplicated. Attached Figure Description

[0017] The invention will be more readily understood from the following detailed description with reference to the accompanying drawings, wherein like reference numerals designate units of the same structure, and wherein:

[0018] Figure 1 A schematic flowchart illustrating a method for detecting devices at a gateway according to an embodiment of the present invention is shown.

[0019] Figure 2 This is a schematic flowchart illustrating a more detailed method for detecting devices at a gateway according to an embodiment of the present invention;

[0020] Figure 3 This is a schematic diagram illustrating the user interface according to an embodiment of the present invention;

[0021] Figure 4 This is a schematic diagram illustrating the returned detection results according to an embodiment of the present invention;

[0022] Figure 5 A schematic flowchart illustrating a method for self-learning device entries according to an embodiment of the present invention is shown.

[0023] Figure 6 A more detailed schematic flowchart of a method for self-learning device entries according to an embodiment of the present invention is shown.

[0024] Figure 7 A schematic block diagram of a gateway according to an embodiment of the present invention is shown; and

[0025] Figure 8 A schematic block diagram of a control panel including a gateway according to an embodiment of the present invention is shown. Detailed Implementation

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

[0027] Furthermore, it should be noted that in this specification, A connected to B can mean "A is directly connected to B" or "A is connected to B via other middleware". A connected between B and C can mean "A is directly connected to both A and B" or "A is connected to both B and C via other middleware".

[0028] In recent years, the wave of digitalization has swept through the entire power distribution industry, playing an irreplaceable and significant role in supporting industrial upgrading. Power distribution digitalization refers to upgrading and transforming electrical systems using interconnected intelligent devices and supporting management software, thereby improving energy efficiency and reducing risks. Taking the core asset panel in a power distribution system as an example, various measuring meters supporting Modbus-RTU communication are commonly installed to monitor the electrical parameters of the main circuit. Typically, each panel can be equipped with a gateway, which connects to each meter via an RS-485 bus and reads the meter's electrical parameter data through the Modbus-RTU protocol. This data is ultimately collected by the SCADA (Supervisory Control and Data Acquisition) system through the gateway for data monitoring and analysis.

[0029] Figure 1 A schematic flowchart of a method 100 for detecting devices at a gateway according to an embodiment of the present invention is shown.

[0030] like Figure 1 As shown, in method 100 at step 101, a probe request is created and sent to one or more devices based on a self-learning device table entry.

[0031] At step 102, determine whether a response packet was received from the device within the predetermined time period.

[0032] In step 103, when a reply packet is received, it is determined whether the data length of the reply packet matches the expected length.

[0033] In step 104, when the data length of the reply packet does not match the expected length, an address conflict of the device is determined.

[0034] Therefore, according to embodiments of the present invention, probe requests can be created for multiple devices based on the self-learned device entries stored in the gateway, enabling one-click detection of multiple devices. Furthermore, it can also detect whether device addresses conflict or are duplicated.

[0035] In one example, the method 100 may further include: determining that the device's parameter configuration is incorrect or the cable connection is incorrect when no reply packet is received.

[0036] In one example, the method 100 may further include: determining that the device address is normal when the data length of the reply packet matches the expected length.

[0037] A mismatch between the data length of the response packet and the expected length can include either the data length of the response packet being greater than the expected length or less than the expected length.

[0038] In one example, a probe request is created for one or more devices corresponding to entries in the device table where the device address is valid.

[0039] In one example, the method 100 may further include: returning the detection results of the one or more devices.

[0040] Figure 2 This is a schematic flowchart illustrating a more detailed method 200 for detecting devices at a gateway according to an embodiment of the present invention, which can be performed by a gateway in a distribution cabinet.

[0041] Figure 3 This is a schematic diagram illustrating the user interface according to an embodiment of the present invention, and Figure 4 This is a schematic diagram illustrating the returned detection results according to an embodiment of the present invention.

[0042] like Figure 2 As shown, in step 201 of method 200, the probe is initiated. For example, in... Figure 3 On the interface shown, you can start the detection of all devices managed by the gateway by clicking the "Start" button.

[0043] In section 202, self-learning device entries can be traversed. Self-learning of device entries refers to the automatic maintenance and / or updating of entries in the device table based on access requests from the host computer. This will be discussed later. Figure 5 and Figure 6 Provide a detailed description.

[0044] In 203, a probe request can be created for one or more devices that correspond to a valid device address in the device table entry.

[0045] Each entry in a device table can include the device address, register address, number of registers, and number of times it has not been updated. For example, an example of a device table entry can be shown in Table 1 below.

[0046] Table 1. Array of Device Entries (Maximum Quantity: 16)

[0047] name illustrate Device address Device address Register address The starting register address to read Number of registers Number of registers to read Number of times not updated 0~65535

[0048] In Table 1, a maximum of 16 entries, representing information for 16 devices, can be stored in the device table entries. However, those skilled in the art will understand that the embodiments of the present invention are not limited to this, and device table entries can store more or fewer entries. The device address can be one byte. The register address indicates the address of the first register to be read, ranging from 0x0000 to 0xFFFF, and can be two bytes. The register number indicates the number of registers to be read, ranging from 1 to 125, and can be two bytes.

[0049] The "Not Updated" count indicates the number of times the host computer has not accessed the device. The maximum "Not Updated" count can be set to 65535. Whether to invalidate a device's address can be determined based on the "Not Updated" count for each device in the device table entry; for example, the device address can be invalidated by setting it to 0.

[0050] For each device whose device address is not 0 (i.e., the device address is valid) in the device table entry, a probe request can be created.

[0051] In one example, a request can be constructed based on the Modbus protocol according to the register address and number of registers for each entry in the device table. For example, a ModbusRTU request packet with FunctionCode=3 can be constructed.

[0052] At 204, the constructed request packet is sent to the corresponding device.

[0053] In one example, 30 request packets can be sent for each device. That is, 30 request packets are sent for each of one or more devices whose device addresses are valid in the device table entry.

[0054] In one example, a predetermined response time period can be set to wait for a response packet after sending each request packet. The predetermined response time period could be, for example, 300ms. However, embodiments of the present invention are not limited to this.

[0055] At step 205, after sending a request packet, it is determined whether a response packet has been received within the scheduled response period.

[0056] If no response packet is received within the predetermined response period (No in 205), then method 200 proceeds to 206. In 206, it can be determined that the device parameters are misconfigured or the cable connection is incorrect.

[0057] In step 205, if a response packet is received within the predetermined response time period (as is the case in step 205), then method 200 proceeds to step 207. In step 207, it can be determined whether the data length of the response packet matches the expected length.

[0058] In step 207, if the data length of the response packet matches the expected length (as it is in step 207), then step 200 proceeds to step 208. In step 208, it can be confirmed that the device address is correct.

[0059] In one example, in 208, a further CRC check can be performed on the reply packet, such as... Figure 2 As shown in the dashed box, when the reply packet is successfully verified, it is determined that the device address is normal.

[0060] In step 207, if the data length of the response packet does not match the expected length (No in step 207), then step 200 proceeds to step 209. In step 209, it is determined that there is an address conflict for the device.

[0061] In one example, determining that the data length of the response packet does not match the expected length can include either the data length of the response packet being greater than the expected length or less than the expected length.

[0062] Based on the constructed request packet, the correct length of the response packet can be predicted. For example, for a Modbus RTU request packet with FunctionCode=3, the correct length of the response packet, i.e., the expected length, can be known in advance based on the number of registers requested to be read and the number of fixed headers. If the data length of the response packet is greater than or less than the expected length, an address conflict of the device can be determined.

[0063] After probing all devices with valid device addresses in the device table entries, the probe results can be returned, such as... Figure 4 As shown in the image.

[0064] like Figure 4 As shown, a total of 16 devices with addresses 1 to 16 were detected. Among them, devices with conflicting addresses are 5 and 6; devices with no response are 1, 2, 4 and 7, meaning that devices with addresses 1, 2, 4 and 7 have incorrect parameter configurations or cable connections; and the normal device addresses are 9, 10, 11, 12, 13, 14, 15, 16, 3 and 8.

[0065] Therefore, according to embodiments of the present invention, multiple devices can be detected with a single click, and the detection results for all devices can be returned, improving troubleshooting efficiency. Furthermore, the method for detecting devices at the gateway according to embodiments of the present invention can utilize the gateway already deployed and running on-site, requiring no additional hardware support. In addition, embodiments of the present invention can utilize open WebAPI interfaces, thereby enabling seamless integration with SCADA systems.

[0066] Below, we will refer to Figure 5 This invention describes a process for self-learning device entries according to an embodiment of the invention.

[0067] According to embodiments of the present invention, the process for self-learning device entries may include an update process and an aging process. The update process may update the information recorded in the entries of the device entries, and the aging process may invalidate older entries in the device entries for subsequent recording of new entries.

[0068] Figure 5A schematic flowchart of a method 500 for self-learning device entries according to an embodiment of the present invention is shown. The method 500 may involve an update process and may be performed by a gateway in a power distribution cabinet.

[0069] In method 500, step 501, a request to read the device's registers can be received from the host computer.

[0070] A 502 error can determine whether the address of the device to be read in the request is included in the device table entry.

[0071] In 503, when the address of the device to be read is included in the device table entry, it can be determined whether the number of registers to be read in the request is less than the number of registers of the corresponding device in the device table entry.

[0072] In 504, when the number of registers to be read is less than the number of registers for the corresponding device in the device table entry, the register address and register count for the corresponding device in the device table entry can be updated to the register address and register count for the device included in the request.

[0073] In 505, the number of times the device has not been updated in the device table entry is set to zero.

[0074] Therefore, according to embodiments of the present invention, whenever a request to read the registers of a device is received from a host computer, the device entries can be automatically updated so that the information recorded in the entries of the device entries corresponds to the latest information of the device, thereby realizing the self-learning of the device entries.

[0075] In one example, self-learning of device entries can ensure that the number of device registers in each entry is minimized.

[0076] In one example, when the number of registers to be read is not less than the number of registers for the corresponding device in the device table entry, the number of times the device has not been updated in the device table entry can be set to zero.

[0077] In other words, if the address of the device to be read in the request is included in the device table entry, then the number of unupdated entries for that device can be set to zero if the number of registers to be read is less than or greater than the number of registers of the corresponding device in the device table entry.

[0078] In one example, when the address of the device to be read is not included in the device table entry, the unupdated count of all entries in the device table entry can be incremented by 1, and the information of the device to be read can be recorded in the device table entry.

[0079] In one example, when the number of times an entry in a device table is not updated reaches a threshold, the device address of that entry can be invalidated.

[0080] In one example, recording the device information to be read in the device table entry can include one of the following: if there is a blank entry in the device table, the device information to be read is recorded in the blank entry as a new device; if there is an entry in the device table with an invalid device address, the device information to be read is recorded in the entry with the invalid device address as a new device; and if there are neither blank entries nor invalid device address entries in the device table, the device information to be read is recorded in the entry with the maximum number of times it has not been updated as a new device.

[0081] Figure 6 A more detailed schematic flowchart of a method 600 for self-learning device entries according to an embodiment of the present invention is shown. The method 600 may involve an update process and aging, and may be performed by a gateway in a distribution cabinet.

[0082] like Figure 6 As shown, in step 601 of method 600, the gateway is powered on and running.

[0083] In 602, the host computer can connect to the gateway, and the gateway can receive requests from the host computer.

[0084] In step 603, it can be determined whether the request is for reading a device register.

[0085] When the gateway receives a request from the host computer to read the device's registers, it can trigger the gateway's self-learning of device entries. For example, when the host computer accesses the device registers on the RS-485 bus via ModBusTCP, the gateway's self-learning function can be triggered.

[0086] The host computer's request to read device registers can be a Modbus TCP request. In the case of a Modbus TCP request, it can be determined whether the FunctionCode equals 3. If the FunctionCode = 3, it is determined that it is a request to read device registers, and the process can proceed to step 604. Otherwise, the process proceeds to step 608. At step 608, the self-learning process ends.

[0087] In 604, by retrieving all entries in the device table, it can be determined whether the device address to be read in the request received from the host computer is included in the device table entry.

[0088] At 604, if the device address to be read in the request is included in the device table entry (Yes in 604), the procedure proceeds to 605. Otherwise (No in 604), the procedure proceeds to 609.

[0089] In 605, it can be determined whether the number of registers to be read in the request is less than the number of registers for the corresponding device in the device table entry.

[0090] At 605, if the number of registers to be read in the request is less than the number of registers for the corresponding device in the device table entry (yes in 605), the procedure proceeds to 606. Otherwise (no in 605), the procedure proceeds to 607.

[0091] At 606, the register address and register count of the corresponding device in the device table entry can be updated to the register address and register count of the device included in the request, and the process proceeds to 607.

[0092] At 607, the number of times the device has not been updated in the device table entry can be set to zero. Then, the self-learning process ends at 608.

[0093] In 609, if the device address to be read in the request is not included in the device table entry, the unupdated count of all entries in the device table entry can be incremented by 1.

[0094] At step 610, it can be determined whether the number of times each entry in the device table has not been updated has reached a threshold number. For example, the threshold number could be 65535, but the embodiments of the present invention are not limited thereto.

[0095] At 610, if the number of times an entry in the device table has not been updated reaches the threshold number (yes in 610), the process proceeds to 611. Otherwise (no in 610), the process proceeds to 612.

[0096] If an entry's number of unupdated entries reaches a threshold, it indicates that the device may not have been accessed for an extended period and is likely invalid, thus it can be removed from the device table entry. Therefore, in section 611, the device address of that entry can be invalidated.

[0097] A device address can be invalidated by setting it to a specific value. Alternatively, a flag indicating whether the address is valid can be set in the device table entry; for example, a single bit can be used to indicate whether an address is valid or invalid.

[0098] At step 612, the information of the device to be read is recorded in the device table as an entry for the new device. Then, the process proceeds to step 608, at which point the self-learning process ends.

[0099] In one example, if a blank entry exists in the device table, the information of the device to be read can be recorded in the blank entry, treating it as a new device. In another example, if an invalid device address exists in the device table, the information of the device to be read can be recorded in the invalid device address entry, treating it as a new device. In yet another example, if neither a blank entry nor an invalid device address exists in the device table, the information of the device to be read can be recorded in the entry with the maximum number of times it has not been updated, treating it as a new device.

[0100] Processes 604, 605, 606, 607, 608, and 612 may involve updating equipment entries, and processes 604, 609, 610, and 611 may involve aging-in of equipment entries.

[0101] Therefore, according to embodiments of the present invention, by self-learning the device entries, the device entries can be automatically maintained, so that when probing devices, one-click probing can be performed on all devices included in the device entries based on the latest device entries, thereby improving efficiency.

[0102] Figure 7 A schematic block diagram of a gateway 700 according to an embodiment of the present invention is shown.

[0103] like Figure 7 As shown, gateway 700 may include memory 701 and processor 702. According to an embodiment of the present invention, processor 702 may be coupled to memory 701 and execute reference... Figure 1 , Figure 2 , Figure 5 and Figure 6 The method described.

[0104] Figure 8 A schematic block diagram of a control panel 800 including a gateway is shown according to an embodiment of the present invention.

[0105] like Figure 8 As shown, the disk enclosure 800 may include a gateway, which may include a memory 801 and a processor 802. The processor 802 may be coupled to the memory 801 and execute reference... Figure 1 , Figure 2 , Figure 5 and Figure 6 The method described is for networking.

[0106] Although Figure 1 , Figure 2 , Figure 5 and Figure 6The figures show the steps being performed in a sequential manner; however, those skilled in the art will understand that methods 100, 200, 500, and 600 may be performed in a different order than shown in the figures without departing from the teachings of the embodiments of the invention.

[0107] Those skilled in the art will recognize that the units and algorithm steps of the various embodiments described in conjunction with the embodiments disclosed in this invention can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the composition and steps of each embodiment have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this invention.

[0108] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0109] In the embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0110] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.

[0111] Furthermore, the functional units in the various embodiments of the present invention 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. The integrated unit can be implemented in hardware or as a software functional unit.

[0112] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. 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 the present 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 description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A method for detecting devices at a gateway, the method comprising: Based on self-learning device entries, create probe requests and send probe requests to one or more devices; Determine whether a response packet was received from the device within the scheduled time period; Upon receiving a reply packet, determine whether the data length of the reply packet matches the expected length; and When the data length of the response packet does not match the expected length, an address conflict is identified in the device.

2. The method according to claim 1, further comprising: If no response packet is received, it indicates that the device's parameter configuration is incorrect or the cable connection is incorrect.

3. The method according to claim 1, further comprising: When the length of the response packet matches the expected length, it is determined that the device address is normal. and The mismatch between the data length of the response packet and the expected length includes: The data length of the response packet is either greater than or less than the expected length.

4. The method according to claim 1, wherein, Creating a probe request based on self-learning device entries includes: For one or more devices that correspond to a valid device address in the device table entry, a probe request is created.

5. The method according to claim 4, further comprising: Return the detection results of the one or more devices.

6. The method according to claim 1, wherein, The self-learning of the device entries includes: Receive a request from the host computer to read the device's registers; Determine whether the address of the device to be read in the request is included in the device table entry; When the address of the device to be read is included in the device table entry, determine whether the number of registers to be read in the request is less than the number of registers of the corresponding device in the device table entry; When the number of registers to be read is less than the number of registers for the corresponding device in the device table entry, update the register address and register count of the corresponding device in the device table entry to the register address and register count of the device included in the request; and Set the number of times the device has not been updated in the device table to zero.

7. The method according to claim 6, further comprising: When the number of registers to be read is not less than the number of registers of the corresponding device in the device table entry, the number of unupdated records for that device in the device table entry is set to zero.

8. The method according to claim 6, further comprising: When the address of the device to be read is not included in the device table entry, increment the unupdated count of all entries in the device table entry by 1; as well as The information of the device to be read is recorded in the device table entry.

9. The method according to claim 8, further comprising: When the number of times an entry in the device table is not updated reaches a threshold, the device address of that entry is set to invalid.

10. The method according to claim 9, wherein, The information about the device to be read is recorded in the device table entry, including one of the following: If there are blank entries in the device table, the information of the device to be read will be recorded in the blank entries as a new device; If an entry in the device table contains a device with an invalid address, the information of the device to be read is recorded in the entry with the invalid device address, treating it as a new device; and If there are no blank entries or invalid device addresses in the device table, the information of the device to be read is recorded in the entry with the maximum number of times it has not been updated, and it is treated as a new device.

11. A gateway in a power distribution system, comprising: Memory; as well as A processor, coupled to the memory and configured to perform the method of any one of claims 1-10.

12. A control panel including a gateway in a power distribution system, the gateway comprising: Memory; as well as A processor, coupled to the memory and configured to perform the method of any one of claims 1-10.