Software function automation test system for communication unit of electric energy meter

By designing the software function automation test system of the power meter communication unit, using the combination of upper computer, detection device and listening device, the lack of functional testing automation of communication unit software in the prior art is solved, and the rapid and accurate communication unit is achieved automated testing.

CN119135584APending Publication Date: 2024-12-13CHINA GRIDCOM
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411127631.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-15
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

The prior art lacks effective automated testing methods to conduct software functional testing of communication units, which affects the upgrade, debugging and fault diagnosis of communication units.

Method used

A software function automation testing system for the power meter communication unit is designed, including a computer, a detection device and a listening device. It is connected to the device under test through simulated electrical data and test interfaces, controls the test operation and obtains test data to realize communication. Automated testing of units.

Benefits of technology

It realizes rapid automated testing of communication units, can determine test results, and improves testing efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119135584A_ABST
    Figure CN119135584A_ABST
Patent Text Reader

Abstract

The invention provides an electric energy meter communication unit software function automatic test system. The test system comprises a communication unit used for testing a power utilization system, and the test system comprises an upper computer, a detection device and an interception device. The detection device is in communication connection with the upper computer, the detection device is used for providing simulated power consumption data, the detection device comprises a plurality of interfaces, the detection device is connected with a tested device through a test interface in the plurality of interfaces, and the tested device comprises a tested communication unit; the interception device is connected with the detection device through an interception interface in the plurality of interfaces, and the interception device is used for intercepting test data related to the tested device; wherein the upper computer is used for running the test software, so that the detection device controls the tested device to execute corresponding test operation and uploads test data acquired by the detection device to the upper computer, and the upper computer outputs a test result based on the test data. Automatic testing of the communication unit of the power utilization system can be realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the technical field of power system testing, and in particular, relates to an automatic testing system for software functions of an electric energy meter communication unit. Background Art

[0002] In the power consumption information collection system, the communication unit is the core unit for data collection. Whether it can operate correctly, efficiently and stably will have a huge impact on the power business. With the continuous expansion of business scenarios, the software structure of communication equipment is becoming increasingly complex. How to test the software functions of the communication unit has become the key to supporting the upgrade, iteration, debugging and fault diagnosis of the communication unit.

[0003] Currently, there is still a lack of effective technical means for automated testing of software functions of communication units. Summary of the invention

[0004] The present application aims to solve at least one of the technical problems existing in the prior art. To this end, the present application proposes an automatic testing system for software functions of a communication unit of an electric energy meter, which can realize automatic testing of the communication unit of an electric power system.

[0005] The embodiment of the present application provides an automatic testing system for software functions of an electric energy meter communication unit, which is used to test the communication unit of an electric power system, and the testing system includes a host computer, a detection device, and a listening device. The detection device is connected to the host computer in communication, and the detection device is used to provide simulated power consumption data. The detection device includes multiple interfaces, and the detection device is connected to the device under test through a test interface among the multiple interfaces, and the device under test includes a communication unit under test; the listening device is connected to the detection device through a listening interface among the multiple interfaces, and the listening device is used to listen to test data related to the device under test; wherein the host computer is used to run the test software so that the detection device controls the device under test to perform the corresponding test operation, and uploads the test data obtained by the detection device to the host computer, and the host computer outputs the test result based on the test data.

[0006] The software function automation test system of the electric energy meter communication unit of the present application is provided with a detection device that can provide simulated electricity consumption data, and is connected to the device under test and the listening device based on the interface of the detection device. The detection device serves as a hub, and controls the device under test to perform corresponding test operations based on the instructions output by the test software of the host computer, and obtains the test data of the communication with the device under test during the test, and obtains the test data of the device under test intercepted by the listening device (such as the test data of the communication between the device under test and other devices), so as to obtain complete test data during the test of the device under test. Based on the complete test data, the test result can be quickly determined, thereby realizing automated testing of the device under test.

[0007] Additional aspects and advantages of the embodiments of the present application will be given in part in the description below, and in part will become apparent from the description below, or will be learned through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0008] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which:

[0009] Figure 1 It is a schematic diagram of an application scenario of an automatic testing system for software functions of an electric energy meter communication unit according to certain embodiments of the present application;

[0010] Figure 2 It is a structural schematic diagram of a system for automatically testing software functions of an electric energy meter communication unit according to certain embodiments of the present application;

[0011] Figure 3 It is a schematic diagram of the structure of the detection device of certain embodiments of the present application. DETAILED DESCRIPTION

[0012] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals represent the same or similar elements or elements having the same or similar functions from beginning to end. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the embodiments of the present application, and cannot be understood as limiting the embodiments of the present application.

[0013] In the present application, unless otherwise clearly specified and limited, a first feature being “above” or “below” a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being “above”, “above”, and “above” a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being “below”, “below”, and “below” a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.

[0014] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one feature. In the description of this application, the meaning of "plurality" is at least two, such as two, three, unless otherwise clearly and specifically defined.

[0015] See also Figure 1 , Figure 1 This is an application scenario diagram of a test system provided in an embodiment of the present application. The application scenario provided in the present application includes a test system 100 and a power consumption system 200, the power consumption system 200 includes a central concentrator 201 and a power consumption collector 202, the central concentrator 201 and the power consumption collector 202 are connected via a power line, and the central concentrator 201 is used to communicate with each power consumption collector 202 to obtain power data collected by each power consumption collector 202.

[0016] The central coordinator 201 (CCO) is a core control unit in the entire power system, responsible for coordinating and managing the communication and data exchange between multiple devices or nodes.

[0017] The power collector 202 may be a smart meter installed at the user end, which can monitor power data in real time, such as voltage, current, power factor, etc., and collect information such as switch status and transformer temperature.

[0018] The power system 200 also includes a device under test 210, which can be at least one of a communication unit of the central concentrator 201 and a communication unit (Station, STA) of the power collector 202. The STA can be a single-phase STA or a three-phase STA. A one-way STA refers to a station module for single-phase power metering. A three-phase STA refers to a station module for three-phase power metering.

[0019] That is, the test system 100 can test at least one of the communication unit of the central concentrator 201 and the communication unit of the power collector 202 .

[0020] It should be noted that Figure 1 The number of central concentrators 201 and power collectors 202 is only for example, and the number of central concentrators 201 and power collectors 202 can be more or less, which is not limited here. The central concentrator 201 and the power collector 202 can be directly or indirectly connected via wired (such as power lines) or wireless communication, which is not limited here.

[0021] The test system of this application is introduced in detail below.

[0022] See also Figure 2 The automatic testing system 100 for the software function of the communication unit of the electric energy meter is used to test the communication unit of the electric power system. The testing system 100 includes a host computer 20, a detection device 10 and a listening device 30. The detection device 10 is connected to the host computer 20 for communication. The detection device 10 is used to provide simulated power consumption data. The detection device 10 includes a plurality of interfaces 11. The detection device 10 is connected to the device under test 210 through a test interface 111 among the plurality of interfaces 11. The device under test 210 includes a communication unit under test. The listening device 30 is connected to the detection device 10 through a listening interface 11 among the plurality of interfaces 11. The listening device 30 is used to listen to the test data related to the device under test 210. The host computer 20 is used to run the test software so that the detection device 10 controls the device under test 210 to perform the corresponding test operation, and uploads the test data obtained by the detection device 10 to the host computer 20. The host computer 20 outputs the test result based on the test data.

[0023] The host computer 20 runs the test software, which can run the test cases, and then sends control instructions to the detection device 10 based on the running test cases. While the detection device 10 generates simulated power consumption data, it controls the device under test 210 through the interface 11, and controls the device under test 210 to perform corresponding test operations, such as controlling the communication unit of the power collector to collect simulated power consumption data, controlling the communication unit of the central concentrator to read the meter, so as to obtain the simulated power consumption data collected by the communication unit of the power collector, etc. In the process of completing the test operation, the detection device 10 can obtain the test data directly communicating with the device under test 210, and can also intercept the test data of the communication between the device under test 210 and other devices (such as the communication data between the power collector and the central concentrator) through the listening device 30. By obtaining the complete test data during the test process and uploading it to the host computer 20, the host computer 20 can quickly evaluate the test results of the device under test 210 (such as whether the test passed, or which test functions failed, etc.) based on the complete test data. In this way, it is only necessary to connect the device under test 210 to the detection device 10 through the test interface 111 , so that the automated test of the device under test 210 can be realized.

[0024] The software function automation test system 100 of the electric energy meter communication unit of the present application is provided with a detection device 10 that can provide simulated power consumption data, and is connected to the device under test 210 and the listening device 30 respectively based on the interface 11 of the detection device 10. The detection device 10 serves as a hub, and controls the device under test 210 to perform corresponding test operations based on the instructions output by the test software of the host computer 20, and obtains the test data of the communication between the device under test 210 during the test, and obtains the test data of the device under test 210 intercepted by the listening device 30 (such as the test data of the communication between the device under test 210 and other devices), so as to obtain the complete test data of the device under test 210 during the test process. Based on the complete test data, the test result can be quickly determined, thereby realizing the automated test of the device under test 210.

[0025] See also Figure 1 and 2 The electric energy meter communication unit software function automatic testing system 100 includes a host computer 20, a detection device 10 and a listening device 30.

[0026] In some embodiments, the host computer 20 may be a terminal device or a server, and the detection device 10 may be connected to the host computer 20 after being connected to the network by connecting to the switch 40 .

[0027] Among them, the terminal device may include but is not limited to: smart phones (such as Android phones, IOS phones, etc.), tablet computers, laptops, desktop computers, portable personal computers, mobile Internet devices (Mobile Internet Devices, referred to as MID), vehicle-mounted terminals, etc., and the embodiments of the present application do not limit this.

[0028] Among them, the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), as well as big data and artificial intelligence platforms, but the embodiments of the present application do not limit this.

[0029] The host computer 20 runs a test software, which includes various test cases to implement automated testing of the device under test 210 .

[0030] For example, when the device under test 210 is a communication unit of the power collector 202, corresponding test cases can be written according to the functions that can be realized by the communication unit of the power collector 202, so as to facilitate testing the functions of the communication unit of the power collector 202 respectively, realize complete testing of each function of the communication unit of the power collector 202, and improve the test effect.

[0031] Optionally, the communication unit of the power collector 202 may implement at least one of the following functions:

[0032] Module networking function, full network upgrade function, remote upgrade function, phase identification function, indicator light function, meter reading function, active event reporting function, communication process function, data transmission function, power outage and restoration event reporting function, version information setting and query function, module identification setting and query function, local code setting and query function and baud rate negotiation function.

[0033] For another example, when the device under test 210 is a communication unit of the central concentrator 201, corresponding test cases can be written according to the functions that can be realized by the communication unit of the central concentrator 201, so as to facilitate testing the functions of the communication unit of the central concentrator 201 separately, realize complete testing of each function of the communication unit of the central concentrator 201, and improve the test effect.

[0034] Optionally, the communication unit of the central concentrator 201 may implement at least one of the following functions:

[0035] Module networking function, full network upgrade function, remote upgrade function, indicator light function, meter reading function, 1376.2 protocol (Power Line Communication Protocol) function, 1376.2 extended protocol function, phase identification function, power outage and restoration event reporting function, version information setting and query function, module identification setting and query function, and local code setting and query function.

[0036] In some embodiments, the detection device 10 is connected to the host computer 20 for communication, and the detection device 10 is the control center of the test system 100. The detection device 10 plays a connecting role, that is, the detection device 10 is connected to the host computer 20 and the device under test 210 respectively.

[0037] Optionally, the detection device 10 is connected to the host computer 20 through a switch 40. Specifically, the host computer 20 is connected to the switch 40 through an Ethernet interface 11, and the detection device 10 is also connected to the switch 40 through the Ethernet interface 11.

[0038] Optionally, the detection device 10 includes a power supply 12 and a controller 13. The power supply 12 is a device for supplying power.

[0039] The power supply 12 includes a first power supply 121 and a second power supply 122, wherein the voltage of the first power supply 121 is lower than the voltage of the second power supply 122. The first power supply 121 is used to supply power to the controller 13, and the second power supply 122 is used to supply power to the device under test 210 through the test interface 111.

[0040] It can be understood that since different devices in the test system 100 have different operating voltages, multiple power supplies 12 with different voltages are required for power supply. The first power supply 121 is used to power the controller 13 with a lower operating voltage (such as 24V), and the second power supply 122 is used to power the device under test 210 through the test interface 111. The device under test 210 generally operates at a voltage of 220V.

[0041] The controller 13 is the core of the detection device 10 and is used to realize the control and scheduling between different devices to complete the test of the communication unit.

[0042] And because there is no actual power consumption collector 202 in the test system 100, in order to build a power consumption information collection environment, the controller 13 of the detection device 10 can automatically generate simulated power consumption data based on a preset program (or the host computer automatically generates simulated power consumption data based on a preset program and then gives it to the controller 13), thereby cooperating with the communication unit of the power consumption collector 202 to jointly constitute a simulated power consumption collector 202.

[0043] When the meter reading function test is performed on the communication unit of the power consumption collector 202, simulated power consumption data can be collected through the communication unit of the power consumption collector 202 to complete the meter reading test.

[0044] Optionally, the controller 13 may include a mainboard 131 and a control unit 132, the control unit 132 is connected to the mainboard 131, or the control unit 132 is arranged on the mainboard 131. The control unit 132 is used to realize control, scheduling and communication, and the mainboard 131 is used to integrate various functional modules. The mainboard 131 is also provided with a plurality of interfaces 11, and the plurality of interfaces 11 include a network port 112, a test interface 111 and a listening interface 113.

[0045] The network port 112 (such as a Socket interface) is used to connect to the switch 40 to achieve communication with the host computer 20; the test interface 111 is connected to the device under test 210 (such as the test interface 111 includes a STA interface and a CCO interface 11, the STA interface is used to connect to the power collector 202, and the CCO interface 11 is used to connect to the central concentrator 201); the listening interface 113 is used to connect to the listening device 30 to achieve communication with the listening device 30.

[0046] Optionally, the STA interface may include a single-phase STA interface and a three-phase STA interface, the single-phase STA interface is used to connect a single-phase STA, and the three-phase STA interface is used to connect a three-phase STA.

[0047] It is understandable that the communication protocols used by different interfaces 11 may be different. For example, the communication protocol of the network port 112 is different from the communication protocol of the test interface 111. Therefore, a processing program for messages of different communication protocols needs to be preset in the control unit 132 to ensure that the control unit 132 can send, receive and parse messages of different communication protocols of each connected device, and finally parse various messages of different communication protocols with test data and upload them to the host computer 20 for subsequent test result evaluation.

[0048] Optionally, the communication protocols of the various devices connected to the mainboard 131 include Q / GDW 1376.1 protocol (a power line carrier communication protocol), Q / GDW 1376.2 protocol (a power line carrier communication protocol), DL / T 645-2007 protocol (used to standardize data exchange between a multi-function electric energy meter and a handheld unit or other data terminal equipment), network port 112 communication protocol (such as various TCP (Transmission Control Protocol) protocols) and other communication protocols.

[0049] Optionally, the main board 131 includes a protocol processing interface, which is used to parse messages of multiple communication protocols. Messages of different protocols transmitted by each interface 11 are processed through the protocol processing interface to obtain communication data.

[0050] That is to say, by encapsulating multiple protocol processing programs to obtain a unified protocol processing interface, the processing of messages of different communication protocols can be realized through the unified protocol processing interface, which can improve communication efficiency.

[0051] Optionally, the functional modules of the embedded software of the mainboard 131 include a communication management module, a protocol processing interface, a serial communication module, and an IO (Input / Output) read / write module.

[0052] The communication management module is responsible for the communication between the mainboard 131 and the host computer 20, the device under test 210, and the listening device 30, etc. It sends various requests according to the communication protocol between the devices, waits for and judges the response of the device, and responds to the requests sent by each device. It communicates with the host computer 20 through the Socket interface and the TCP protocol to realize the setting, query and data transmission and reception of the status of the mainboard 131. The device under test 210 and the accompanying device use the Universal Asynchronous Receiver / Transmitter (UART) interface for communication, and the communication protocol complies with the frame format of the Q / GDW 1376.2 protocol and the DL / T 645 protocol.

[0053] The protocol processing interface is responsible for organizing and parsing communication protocol messages such as Q / GDW 1376.1, Q / GDW 1376.2, DL / T 645-2007, etc. Different types of communication protocols are processed through a unified software interface 11, thereby completing the communication data processing between the control unit 132 and the host computer 20 and various devices.

[0054] The serial communication module is responsible for the data transmission and reception between the control unit 132 and the host computer 20 and the communication interface of each device. The supported interfaces include Socket interface, UART interface, RS-485 interface, etc. It completes the functions of opening and closing each communication interface to ensure the reception and transmission of data.

[0055] The IO read / write module realizes functions such as power on and off, reset, and event triggering of the interface 11 by controlling the power supply 12 and the GPIO (General-Purpose Input / Output) interface.

[0056] Optionally, the multiple interfaces 11 further include a three-phase electrical interface 118 , and the three-phase electrical interface 118 is connected to a second power supply 122 , and the second power supply 122 is used to provide three-phase alternating current.

[0057] It can be understood that since the device under test 210 generally requires 220V three-phase AC power, a second power supply 122 is set and a three-phase electrical interface 118 is set in the controller 13 to input three-phase AC power to the controller 13 through the three-phase electrical interface 118, and power is supplied to the device under test 210 through the test interface 111.

[0058] Optionally, the multiple interfaces 11 include a power line interface 115, and different detection devices 10 are connected to each other through the power line interface 115. The second power supply 122 can be powered through the power line interface 115, and each detection device 10 can communicate through the power line.

[0059] It can be understood that since the test system 100 may include multiple detection devices 10 to respectively implement tests of multiple devices under test 210, in order to avoid the problem of each detection device 10 being connected to the host computer 20 separately, communication data being asynchronous and communication lines being relatively complicated, a power line interface 115 can be set on the main board 131, so that the connection of each detection device 10 can be achieved through the power line interface 115, and one of the detection devices 10 can be used as a hub to achieve communication with each detection device 10, and the test data of each detection device 10 can be unified and uploaded to the host computer 20.

[0060] Optionally, the power line interface 115 and the three-phase electrical interface 118 are coupled to each other.

[0061] In this way, the three-phase electrical interface 118 is coupled to the power line interface 115 to isolate the three-phase electricity, so that only the power line carrier signal is output from the power line interface 115 .

[0062] Optionally, the detection device 10 also includes a reset circuit 14 and an indicator light circuit 15, the reset circuit 14 is used to reset the detection device 10, and the indicator light circuit 15 is used to display status information of the detection device 10, and the first power supply 121 outputs multiple different voltages through a DC-to-DC circuit to provide corresponding voltages for the controller 13, the reset circuit 14 and the indicator light circuit 15.

[0063] In some embodiments, the test system 100 further includes a test companion device 50, which communicates with the device under test 210 to perform a functional test. The test companion device 50 and the device under test 210 may be connected via a power line to perform communication.

[0064] The device under test 210 may be one of the communication units of the central concentrator 201 and the power collector 202, and the accompanying device under test 50 may be the other of the communication units of the central concentrator 201 and the power collector 202. The simulated power consumption data generated by the device under test 210, the accompanying device under test 50 and the controller 13 constitute the power consumption system environment. It can be understood that the various functions of the device under test 210 generally cannot be realized alone and need to be used in the constructed power consumption system environment. Therefore, after the power consumption system environment is constructed, the functions of the device under test 210 can be guaranteed to be realized by controlling the device under test 210 and the accompanying device under test 50 to perform corresponding test operations, thereby realizing the functional test of the device under test 210.

[0065] In order to implement functional testing of both the communication unit of the central concentrator 201 and the communication unit of the power collector 202, the device under test 210 may include the communication unit of the central concentrator 201 and the communication unit of the power collector 202 at the same time, such as first performing a functional test on the communication unit of the central concentrator 201 (in this case, the communication unit of the power collector 202 serves as the accompanying test device 50), and then performing a functional test on the communication unit of the power collector 202 (in this case, the communication unit of the central concentrator 201 serves as the accompanying test device 50).

[0066] Optionally, the multiple interfaces 11 further include a test interface 114 connected to the test device 50 . The test device 50 is connected to the controller 13 via the test interface 114 . The controller 13 can control the test device 50 to perform corresponding test operations, thereby cooperating with the device under test 210 to complete the test.

[0067] Optionally, the second power supply 122 is used to power the companion test device 50 through the companion test interface 114 in the multiple interfaces 11. Similarly, the companion test device 50, like the device under test 210, generally works through 220 AC power. Therefore, both the companion test device 50 and the device under test 210 are powered by the second power supply 122.

[0068] Optionally, the test interface 111 and the accompanying test interface 114 are both Universal Asynchronous Receiver / Transmitter (UART) interfaces.

[0069] Among them, UART is an interface standard for serial communication, usually used in short-distance communication. The UART interface allows asynchronous data transmission between devices, that is, no clock signal is required to synchronize the data flow.

[0070] Optionally, the serial communication standard satisfied by the communication between the controller 13 and each interface 11 is RS-485.

[0071] Among them, RS-485 is an electrical standard for serial communication, commonly used in industrial automation, building automation, instrumentation and other fields. It is a half-duplex, multi-point communication bus standard that can support long-distance data transmission and has strong anti-interference ability.

[0072] In some embodiments, the detection device 10 includes a shielding box 80, and various components of the detection device 10 are located in the shielding box 80 to isolate radiation.

[0073] The shielding box 80 may be a metal shielding box.

[0074] Specifically, in order to avoid the influence of radiation, various components of the detection device 10 may be placed in a shielding box 80 to prevent radiation interference from occurring and affecting the result of the functional test.

[0075] In some embodiments, the detection device 10 further includes a debugging interface 117 .

[0076] The debugging interface 117 is used to print debugging information. The debugging information of the test system 100 refers to logs, warnings, error messages, and other information that helps diagnose and solve problems generated during the development and maintenance of the test system 100. Debugging information is very important for understanding system behavior, locating the root cause of problems, optimizing performance, etc.

[0077] In order to facilitate an overall understanding of the present application, specific examples are provided below for illustration.

[0078] In one example, the test system 100 tests the meter reading function of the communication unit of the electricity collector 202. The test process is as follows:

[0079] (1) Initialization step: Initialize the communication units of the central concentrator 201 and the power collector 202, and the detection device 10, etc., to configure the communication address, frequency band, etc., and restore the parameters of each device to the initial state.

[0080] (2) Test steps: The detection device 10 sends a control instruction to the central concentrator 201 to control the central concentrator 201 to send a meter reading message to the communication unit of the power collector 202. At this time, the listening device 30 can obtain the communication data between the central concentrator 201 and the power collector 202 by listening to the data of the power line between the central concentrator 201 and the power collector 202, which is used as the test data. Then, the communication unit of the power collector 202 collects the simulated power data from the detection device 10 (serial communication data capture), and gives the collected simulated power data to the central concentrator 201 to complete the meter reading of the simulated power data.

[0081] Among them, the communication data between the detection device 10 and the power collector 202, and the communication data between the detection device 10 and the central concentrator 201 can be directly obtained by the detection device 10. The communication data between the central concentrator 201 and the power collector 202 can be obtained by the monitoring device monitoring the data of the power line between the actual concentrator and the actual electric energy meter, thereby obtaining the test data in the entire test process (i.e., the communication data between the detection device 10 and the power collector 202, the communication data between the detection device 10 and the central concentrator 201, and the communication data between the central concentrator 201 and the power collector 202).

[0082] The detection device 10 uploads the test data to the host computer 20, and the host computer 20 evaluates the test data to determine the test result. For example, for the meter reading test, if the power consumption data collected by the power consumption collector 202 and the power consumption data obtained by the central concentrator 201 are consistent with the simulated power consumption data generated by the detection device 10, it can be determined that the meter reading function is normal and the meter reading function test passes. If the power consumption data collected by the power consumption collector 202 or the power consumption data obtained by the central concentrator 201 are inconsistent with the simulated power consumption data generated by the detection device 10, it can be determined that the meter reading function is abnormal and the meter reading function test fails.

[0083] After the host computer 20 determines the test result, the test result can be recorded and displayed, which is convenient for the test personnel to view in time and maintain the device under test 210 based on the test result.

[0084] In another example, the test system 100 tests the setting and querying module identification (Identity document, ID) function of the communication unit of the central concentrator 201. The setting and querying module ID function is used to determine whether the module ID information query and setting function of the communication unit of the central concentrator 201 is normal. The test process is as follows:

[0085] (1) Initialization step: Initialize the communication units of the central concentrator 201 and the electric energy meter 202, and the test device 10, etc., to configure the communication address, frequency band, etc., and restore the parameters of each device to the initial state.

[0086] (2) Test steps: During the test, the detection device 10 sends a module ID information query message to the communication unit of the central concentrator 201 to observe whether the communication unit of the central concentrator 201 can normally reply to the query message. If so, the module ID information is saved to be restored after the test is completed; then, according to the ID information configured in the scheme, a module ID setting message is sent to the communication unit of the central concentrator 201, and the communication unit of the central concentrator 201 is waited for to respond with a successful setting message. After the communication unit of the central concentrator 201 responds, the module ID is queried again.

[0087] The detection device 10 can obtain the queried module ID, and upload the queried module ID and the set module ID to the host computer 20. The host computer 20 determines whether the queried ID information is consistent with the set ID information. If not, the test fails. The detection device 10 can control the communication unit of the central concentrator 201 to restart the module and then query again to test whether the restart of the module will cause the module ID to be lost. If lost, the test fails, otherwise the test passes, and the next test is performed after the module ID is restored.

[0088] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples" or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiments or examples are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, unless they are contradictory.

[0089] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.

[0090] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limitations on the present application. Ordinary technicians in this field can change, modify, replace and modify the above embodiments within the scope of the present application.

Claims

1. An automatic testing system for software functions of an electric energy meter communication unit, characterized in that: A communication unit for testing an electrical system, the test system comprising: Host computer; A detection device, which is communicatively connected to the host computer, and is used to provide simulated power consumption data. The detection device includes a plurality of interfaces, and the detection device is connected to a device under test through a test interface among the plurality of interfaces, and the device under test includes a communication unit under test; A listening device, the listening device is connected to the detection device via a listening interface among the multiple interfaces, and the listening device is used to listen to test data related to the device under test; The host computer is used to run the test software so that the detection device controls the device under test to perform corresponding test operations, and uploads the test data obtained by the detection device to the host computer, and the host computer outputs the test results based on the test data.

2. The test system according to claim 1, characterized in that: The detection device is communicatively connected with the host computer via a switch.

3. The test system according to claim 1 or 2, characterized in that: The detection device comprises: Power supply, used for power supply; A controller includes the plurality of interfaces.

4. The test system according to claim 3, characterized in that: The multiple interfaces include a network port, and the controller is used to communicate with devices connected to each interface and to communicate with the host computer through the network port.

5. The test system according to claim 3, characterized in that: The power supply includes a first power supply and a second power supply, the voltage of the first power supply is lower than the voltage of the second power supply, the first power supply is used to power the controller, and the second power supply is used to power the device under test through the test interface.

6. The test system according to claim 5, characterized in that: The test system further includes a companion test device, which communicates with the device under test to perform a functional test, and the second power supply is used to supply power to the companion test device through a companion test interface among the multiple interfaces.

7. The test system according to claim 5 or 6, characterized in that: The multiple interfaces include a three-phase electrical interface, the three-phase electrical interface is connected to the second power supply, and the second power supply is used to provide three-phase alternating current.

8. The test system according to claim 5, characterized in that: The detection device also includes a reset circuit and an indicator light circuit. The reset circuit is used to reset the detection device, and the indicator light circuit is used to display status information of the detection device. The first power supply outputs multiple different voltages through a DC-to-DC circuit to provide corresponding voltages for the controller, the reset circuit and the indicator light circuit.

9. The test system according to claim 3, characterized in that: The multiple interfaces include a power line interface, and different detection devices are connected to each other through the power line interface and perform power line communication.

10. The test system according to claim 9, characterized in that: The multiple interfaces also include a three-phase electrical interface connected to the power supply, and the power line interface is coupled to the three-phase electrical interface.

11. The test system according to claim 3, characterized in that: The test system further includes a test companion device, the test companion device is used to communicate with the device under test to perform a functional test, the monitoring unit is used to monitor the test data between the device under test and the test companion device, and the multiple interfaces further include a test companion interface connected to the test companion device; The host computer is used to run the test software so that the detection device controls the device under test and the accompanying device to perform corresponding test operations.

12. The test system according to claim 11, characterized in that: The interface under test and the accompanying test interface are both universal asynchronous receiver-transmitter interfaces.

13. The test system according to claim 11, characterized in that: The controller includes a protocol processing interface, which is used to process messages of multiple communication protocols. Messages of different protocols transmitted by each of the interfaces are processed by the protocol processing interface to obtain communication data.

14. The test system according to claim 1, characterized in that: The power consumption system includes a power consumption collector and a central concentrator, and the device under test includes at least one of a communication unit of the power consumption collector and a communication unit of the central concentrator.

15. The test system according to claim 1, characterized in that: The detection device comprises a shielding box, and each component of the detection device is located in the shielding box to isolate radiation.