Electric energy metering method and device, electric meter and storage medium

By obtaining the instantaneous power information output from the metering chip within each power grid cycle, performing synthesis and integration operations, the problem of fixed metering methods and pulse output in traditional power metering technology is solved, and higher accuracy and reliability of power metering are achieved.

CN119936477APending Publication Date: 2025-05-06SHENZHEN STAR INSTR
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510085670.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-20
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

Traditional electric energy metering technology relies on special metering chips, and the metering method is relatively fixed, making it difficult to support multiple active metering methods. The output of the electric energy pulse is not completely synchronized with the register, which affects the accuracy and reliability of the metering.

Method used

During each power grid period, the instantaneous power information output from the metering chip is obtained, and the total instantaneous power is obtained through the integration operation. The accumulated electric energy is obtained, and the power value of the meter is updated when the accumulated electric energy reaches the preset pulse constant.

Benefits of technology

By accurately calculating the power generated by the metering chip, the accuracy and reliability of the power metering are improved, and the system maintenance costs and complexity are reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119936477A_ABST
    Figure CN119936477A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of electric power, in particular to an electric energy metering method and device, an electric meter and a storage medium, and the method comprises the steps: obtaining instantaneous power information output by a metering chip after the metering chip updates effective power and generates power updating interruption in each power grid period, and carrying out the synthesis operation of the instantaneous power information, the total instantaneous power of the current power grid period is obtained, integral operation is carried out on the continuous total instantaneous power of the power grid period to obtain accumulated electric energy, and when the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter. The total instantaneous power is obtained through synthesis operation of instantaneous power information output by the metering chip, the accumulated electric energy is obtained through integral operation of the total instantaneous power, and the electric energy value of the electric meter is updated according to the accumulated electric energy. Therefore, the power generated by the metering chip is calculated accurately and comprehensively, and the accuracy of electric energy metering is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of electric power technology, and in particular to an electric energy metering method, device, electric meter and storage medium. Background Art

[0002] With the development of smart grids, higher requirements are placed on the accuracy, flexibility, reliability and cost of electricity metering. Traditional electricity metering mostly uses dedicated hardware metering chips for electricity calculation. These chips sample voltage and current and perform power calculation and energy accumulation internally, and output fixed electricity pulse signals. However, with the changes in demand and the development of technology, traditional metering solutions are facing more and more challenges, and more flexible and efficient solutions are needed.

[0003] Existing electric energy metering technology mainly relies on dedicated metering chips to directly output pulse signals. The metering method of dedicated metering chips is relatively fixed, and the support for various active metering methods is not flexible enough. If the metering method needs to be upgraded or changed, in most cases, it is necessary to replace the metering chip or perform hardware modification, which increases the maintenance cost and complexity of the system. In the traditional solution, the electric energy pulse is directly output by the metering chip. Since the electric energy register and the pulse output are not completely synchronized, it is difficult to ensure that the number of pulses is completely consistent with the actual stored accumulated electric energy value, which affects the accuracy and reliability of the metering.

[0004] Therefore, how to accurately and comprehensively calculate the power generated by the metering chip in order to accurately and efficiently complete the electric energy metering has become an urgent problem to be solved. Summary of the invention

[0005] The embodiments of the present invention provide an electric energy metering method, an apparatus, an electric meter and a storage medium to solve the problem of how to accurately and comprehensively calculate the power generated by a metering chip to accurately and efficiently complete electric energy metering.

[0006] In a first aspect, an embodiment of the present invention provides an electric energy metering method, comprising: After the metering chip updates the effective power and generates a power update interrupt in each power grid cycle, the instantaneous power information output by the metering chip is obtained; Performing a synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle; Integrating the total instantaneous power of the continuous power grid cycle to obtain accumulated electric energy; When the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter.

[0007] In a second aspect, an embodiment of the present invention provides an electric energy metering device, comprising: The instantaneous power acquisition module is used to obtain the instantaneous power information output by the metering chip after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle; A synthesis operation module, used for performing synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle; An integration module, used for integrating the total instantaneous power of the continuous power grid cycle to obtain accumulated electric energy; The electric energy updating module is used to update the electric energy value of the electric meter using the accumulated electric energy when the accumulated electric energy reaches a preset pulse constant.

[0008] In a third aspect, an embodiment of the present invention provides an electric meter, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the electric energy metering method when executing the computer program.

[0009] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the above-mentioned electric energy metering method is implemented.

[0010] Compared with the prior art, the present invention has the following beneficial effects: after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle, the instantaneous power information output by the metering chip is obtained, the instantaneous power information is synthesized and calculated to obtain the total instantaneous power of the current power grid cycle, the total instantaneous power of the continuous power grid cycle is integrated to obtain the accumulated electric energy, and when the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter. The total instantaneous power is obtained by synthesizing the instantaneous power information output by the metering chip, the accumulated electric energy is obtained by integrating the total instantaneous power, and the electric energy value of the electric meter is updated according to the accumulated electric energy. Thus, the power generated by the metering chip is accurately and comprehensively calculated, and the accuracy of electric energy metering is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.

[0012] Figure 1 This is a schematic diagram of an application environment of an electric energy metering method provided in Embodiment 1 of the present invention; Figure 2 is a flow chart of an electric energy metering method provided in Embodiment 2 of the present invention; Figure 3 is a flow chart of an electric energy metering method provided in Embodiment 3 of the present invention; Figure 4 is a flow chart of an electric energy metering method provided in Embodiment 4 of the present invention; Figure 5 is a flowchart of an electric energy metering method provided in Embodiment 5 of the present invention; Figure 6 is a flowchart of an electric energy metering method provided in Embodiment 6 of the present invention; Figure 7 is a flow chart of an electric energy metering method provided in Embodiment 7 of the present invention; Figure 8 is a flow chart of an electric energy metering method provided in Embodiment 8 of the present invention; Fig. 9 is a structural schematic diagram of an electric energy metering device provided in Embodiment 9 of the present invention; Fig.10 It is a structural schematic diagram of an electric meter provided in Embodiment 10 of the present invention. DETAILED DESCRIPTION

[0013] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0014] like Figure 1 As shown, it is a schematic diagram of an application environment of an electric energy metering method provided in the first embodiment of the present invention, wherein the electric meter end and the server end are connected to communicate to provide the server end with electric energy metering results. The electric meter end includes, but is not limited to, an electric meter containing a single multi-phase metering chip and an electric meter containing multiple single-phase metering chips. The server end can be implemented by an independent server or a server cluster composed of multiple servers.

[0015] like Figure 2 FIG. 1 is a flow chart of an electric energy metering method provided in Embodiment 2 of the present invention, wherein the electric energy metering method is applied in Figure 1 The electric energy metering method may include the following steps: Step S201, after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle, the instantaneous power information output by the metering chip is obtained.

[0016] Among them, the grid cycle is usually fixed, for example, the grid cycle of 50Hz is 20 milliseconds, and the grid cycle of 60Hz is 16.67 milliseconds. Instantaneous power information includes but is not limited to active power, reactive power, and apparent power. A multi-phase metering chip (such as a three-phase metering chip) or a combination of multiple single-phase metering chips can be used to meet the metering requirements of two-phase three-wire, three-phase four-wire, and three-phase three-wire. The metering chip outputs instantaneous active power, reactive power, and apparent power data to the MCU (Microcontroller Unit) through interfaces such as SPI and UART. The metering chip updates the effective power value once every grid cycle, generates a power update interrupt, and triggers the MCU to read the instantaneous power information output by the metering chip.

[0017] Step S202, performing synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle.

[0018] The MCU runs a software integration algorithm to achieve accurate software integration to calculate electric energy. Each time the metering chip updates the instantaneous power information, an instantaneous power information update interrupt is generated. After receiving the interrupt, the MCU reads the instantaneous power value (the instantaneous power value is called the value of each phase) and synthesizes and calculates the power data of each phase as needed (such as different metering methods). For multiple single-phase metering chips and a single multi-phase metering chip, different calculation methods are used for synthesis operations to obtain the total instantaneous power corresponding to multiple single-phase metering chips and the total instantaneous power corresponding to a single multi-phase metering chip. The total instantaneous power is called the combined phase value.

[0019] Step S203, integrating the total instantaneous power of the power grid periodically to obtain accumulated electric energy.

[0020] Among them, since the power grid cycle is usually fixed, we need to calculate the time interval since the last interruption. The integral operation multiplies the total instantaneous power value of each power grid cycle by the corresponding time interval, and then accumulates it to the accumulated electric energy. The MCU sets an accurate 250μs hardware timer interrupt cycle. Each time an interrupt occurs, the MCU uses 1 / 4000 of the current effective value of the combined power as the incremental value of this integration and accumulates it into the total electric energy value. In this way, each power value is evenly distributed to several 250μs cycles, ultimately achieving an accurate integration effect.

[0021] Step S204, when the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter.

[0022] Among them, the MCU is connected to the server through the communication module, the MCU receives the instantaneous power information transmitted by the metering chip, calculates the electric energy inside the MCU, and obtains the accumulated electric energy. When the accumulated electric energy meets the preset pulse constant, the result of electric energy metering is provided to the server and displayed on the meter end through LCD or LED.

[0023] MCU outputs pulse signals through precise hardware timer and GPIO control. Since pulses are generated by MCU in real time according to calculation results, the number of pulses is 100% consistent with the accumulated energy value stored in MCU. MCU can display the accumulated energy, active, reactive and apparent energy data on LCD or LED, or store them in internal / external memory. MCU compares the accumulated energy value with the preset meter constant (pulse constant). When the accumulated energy reaches the energy increment required to output a pulse, MCU triggers GPIO to output a pulse through the timer, and updates the accumulated energy and pulse count data synchronously. When the accumulated energy reaches the pulse constant, we need to add these energy values ​​to the energy value of the meter, and generate pulse signals to indicate the increase of energy value.

[0024] In the embodiment of the present application, after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle, the instantaneous power information output by the metering chip is obtained, the instantaneous power information is synthesized, the total instantaneous power of the current power grid cycle is obtained, the total instantaneous power of the continuous power grid cycle is integrated, and the accumulated electric energy is obtained. When the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter. The total instantaneous power is obtained by synthesizing the instantaneous power information output by the metering chip, the accumulated electric energy is obtained by integrating the total instantaneous power, and the electric energy value of the electric meter is updated according to the accumulated electric energy. In this way, the power generated by the metering chip is accurately and comprehensively calculated, and the accuracy of electric energy metering is improved.

[0025] like Figure 3 FIG. 2 is a flow chart of an electric energy metering method provided in Embodiment 3 of the present invention. In step S202, the instantaneous power information is synthesized to obtain the total instantaneous power of the current power grid cycle, which may include the following steps: Step S301: if the metering chip is a single multi-phase metering chip, then the instantaneous power value of each phase corresponding to the single multi-phase metering chip is obtained according to the instantaneous power information output by the metering chip.

[0026] Among them, a single multi-phase metering chip can use a multi-phase metering chip (such as a three-phase metering chip), and set the instantaneous active power or instantaneous reactive power or instantaneous apparent power of each phase output according to the meter specifications. The three-phase metering chip provides instantaneous power information through the SPI communication interface, reads the value of the corresponding register and converts it into an instantaneous power value.

[0027] Step S302, summing up the instantaneous power values ​​of each phase to obtain the total instantaneous power of the current power grid cycle.

[0028] Among them, for a single multi-phase metering chip, the sum of the instantaneous power values ​​of each phase can be calculated to obtain the total instantaneous active power value of the current power grid cycle.

[0029] In this embodiment, the total instantaneous power of the current power grid cycle is obtained by adding the instantaneous power of each phase of a single multi-phase metering chip, thereby providing a basis for subsequent electric energy integration and pulse output control.

[0030] like Figure 4 As shown, it is a flow chart of an electric energy metering method provided by Embodiment 4 of the present invention. In step S202, the instantaneous power information is synthesized to obtain the total instantaneous power of the current power grid cycle, which may include the following steps: Step S401: If the metering chips are multiple single-phase metering chips, the multiple single-phase metering chips are analyzed to obtain metering requirements.

[0031] Among them, in the case of multiple single-phase metering chips, first, it is necessary to identify and configure each single-phase metering chip to ensure that they work normally and can read instantaneous power information, read the instantaneous power value of each chip through the communication interface, verify the read data to ensure the accuracy and completeness of the data, and store the read data in the corresponding variables for subsequent processing.

[0032] Step S402: Determine the metering mode according to the metering requirement.

[0033] Among them, according to the content of the above step S401, analysis is performed to determine the measurement requirements of the system, including the required measurement mode, accuracy requirements, data processing method, etc., and a suitable measurement mode is selected according to the application requirements, such as algebraic calculation method, vector calculation method or absolute value calculation method.

[0034] Step S403, performing synthesis operation on the instantaneous power information according to the metering mode to obtain the total instantaneous power of the current power grid cycle.

[0035] Among them, the meter designed for multi-phase power grid can use different calculation methods to aggregate the measurement values ​​of each phase to meet the measurement needs under unbalanced load conditions or when each phase has input and output power at the same time.

[0036] Among them, when using the algebraic calculation method, the total phase value of the input active power only includes the values ​​of each phase with positive active power, and the total phase value of the output active power only includes the values ​​of each phase with negative active power. The calculation formula of the algebraic calculation method is as follows: , >0; , <0; In the formula, is the value of each phase with positive active power, is the total phase value of the input active power, is the value of each phase with negative active power, It is the total phase value of output active power.

[0037] When the vector calculation method is used, the product vectors of the voltage, current and power factor of each phase are summed to form the phase value. According to the sign of the phase value, if the measured active power is positive (i.e. ≥0), it is recorded as input active power; if the measured active power is negative (i.e. <0), then it is recorded as output active power; The calculation formula of the vector calculation method is as follows: , >0; , <0; ; ; In the formula, is the total phase value of the input active power, is the combined phase value of the output active power, is the value of each phase of active power.

[0038] When using the absolute value calculation method, the absolute value of the product of each phase voltage, current and power factor is added to obtain the phase value. You can use different and The register that stores the value calculated by absolute value is not available. The register stores this value. The register is zero.

[0039] The calculation formula of the absolute value method is as follows: ; ; ; In the formula, is the total phase value of the input active power, is the value of each phase of active power.

[0040] In this embodiment, the total instantaneous power is obtained by obtaining the metering requirements from multiple single-phase metering chips, determining the metering mode according to the metering requirements, and performing a synthesis operation of the instantaneous power information according to the metering mode, thereby paving the way for subsequent electric energy metering and power analysis.

[0041] like Figure 5 As shown, it is a flow chart of an electric energy metering method provided in Embodiment 5 of the present invention. In step S203, the total instantaneous power of the continuous power grid cycle is integrated to obtain the accumulated electric energy, which may include the following steps: Step S501, obtaining a preset power grid interruption period, calculating the total instantaneous power according to the power grid interruption period, and obtaining a single power effective value.

[0042] Step S502, integrating the continuous single effective power value of the power grid period to obtain accumulated electric energy.

[0043] Among them, the power grid interruption cycle can refer to that the MCU sets an accurate 250μs hardware timer interruption cycle. Each time the interruption occurs, the MCU uses 1 / 4000 of the current effective value of the combined power as the incremental value of this integration. The incremental value is a single effective power value and is accumulated into the total electric energy value. In this way, each power value is evenly distributed to several 250μs cycles, and finally an accurate integration effect is achieved, thereby obtaining the accumulated electric energy.

[0044] In this embodiment, the total instantaneous power is calculated to obtain a single effective power value, and the single effective power value is integrated to obtain the accumulated electric energy, thereby achieving an accurate integration effect and ensuring that the accumulated electric energy can be displayed synchronously.

[0045] like Figure 6 FIG. 2 is a flow chart of an electric energy metering method provided in Embodiment 6 of the present invention. Before the electric energy value of the electric energy meter is updated by using the accumulated electric energy in step S204, the electric energy metering method may further include the following steps: Step S601: When the accumulated electric energy reaches a preset pulse constant, the metering chip outputs a pulse signal.

[0046] Among them, the pulse constant represents the number of pulses output per unit of electrical energy (such as 1kWh). This constant is usually pre-set by the manufacturer of the meter according to the accuracy and design requirements of the meter. The accumulated electrical energy is the total electrical energy consumed from the start of the meter to the current moment. The accumulated electrical energy is updated in each grid cycle (or each power update). When the accumulated electrical energy reaches or exceeds the energy threshold corresponding to the pulse constant, a pulse signal needs to be output. The metering chip generates a pulse signal, usually a short high-level pulse. This pulse signal will be sent to the input of the meter. The meter will update the electrical energy value based on the received pulse signal. Each pulse signal corresponds to a certain electrical energy value.

[0047] Step S602, inputting a pulse signal into the electric meter to obtain a pulse light response of the electric meter.

[0048] Among them, the generated pulse signal needs to be input into the electric meter through a pulse input pin. The pulse input pin is a digital input pin that can detect changes in high and low levels. After the electric meter receives the pulse signal, it will trigger the response of the pulse light, indicating an increase in electric energy. The response of the pulse light can be indicated by the on and off of an LED light.

[0049] In this embodiment, the pulse signal is outputted by the metering chip, and the pulse light responds after the electric meter receives the pulse signal, thereby ensuring the accuracy of the electric energy value update of the electric meter and visual feedback. The on and off of the pulse light not only provides an intuitive reminder of the increase in electric energy, but also facilitates the calibration and maintenance of the electric meter.

[0050] like Figure 7 FIG. 2 is a flow chart of an electric energy metering method provided in Embodiment 7 of the present invention. After obtaining the accumulated electric energy in step S203, the electric energy metering method may further include the following steps: Step S701, obtaining the accumulated power corresponding to the accumulated electric energy according to the accumulated electric energy.

[0051] Step S702, calculating the accumulated power and the pulse constant to obtain the pulse width.

[0052] Step S703, adjusting the accumulated electric energy according to the pulse width to obtain a stabilized accumulated electric energy.

[0053] Step S704: When the accumulated electric energy after stabilization reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter.

[0054] Among them, the accumulated power is the average power over a period of time, and the pulse width refers to the duration of each pulse signal, which can be calculated by the accumulated power and the pulse constant. The required pulse width can be calculated according to the 50% duty cycle, thereby automatically adjusting the pulse width.

[0055] The adjustment of pulse width is to ensure the stability of energy metering. By adjusting the pulse width, the fluctuation of energy value can be reduced, making energy metering more accurate. The pulse width is used to adjust the update frequency of accumulated energy. If the pulse width is long, the update frequency of accumulated energy will be reduced, and vice versa. A queuing mechanism or time window can be used to ensure the stability of accumulated energy within a certain period of time. The stabilized accumulated energy refers to the adjusted accumulated energy, ensuring that the change of energy value within a certain period of time is smooth. A smoothing algorithm (such as moving average) can be used to achieve stability adjustment of energy value.

[0056] In this embodiment, the accumulated power is obtained, the accumulated power and the pulse constant are calculated to obtain the pulse width, the accumulated electric energy is adjusted according to the pulse width, and the electric energy value of the electric meter is updated, thereby ensuring the stable display of the electric meter.

[0057] like Figure 8 FIG. 2 is a flow chart of an electric energy metering method provided in Embodiment 8 of the present invention. After obtaining the accumulated electric energy in step S203, the electric energy metering method may further include the following steps: Step S801, adjusting the pulse constant by adopting the pulse doubling strategy to obtain a doubled pulse constant.

[0058] Step S802, according to the doubled pulse constant, the step of acquiring the instantaneous power information output by the metering chip is performed to obtain the accumulated electric energy of the accelerated output.

[0059] Step S803: if the accumulated electric energy outputted by acceleration meets the doubled pulse constant, the electric energy representation of the accumulated electric energy after acceleration is outputted.

[0060] Among them, the pulse doubling strategy can be used in the small current segment to double the speed of the pulse output and improve the meter inspection efficiency during production. For example, the meter constant is temporarily adjusted to a multiple of the original meter constant. The pulse doubling strategy refers to multiplying the original pulse constant by 2 to improve the frequency and accuracy of energy measurement, obtain instantaneous power information from the energy metering chip, calculate the energy increment per unit time based on the instantaneous power and time interval, and adjust the update frequency of the accumulated energy based on the doubled pulse constant. Each time the accumulated energy output of the accelerated output is updated, check whether it reaches the doubled pulse constant value. If the accumulated energy output of the accelerated output reaches the doubled pulse constant value, the accumulated energy after acceleration is output and the energy value of the meter is updated.

[0061] In this embodiment, the pulse constant is doubled to obtain the accumulated electric energy of the accelerated output, and the accumulated electric energy after acceleration is output to the electric energy display, thereby increasing the updating frequency of the electric energy value by increasing the pulse constant.

[0062] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0063] like Fig. 9 FIG. 1 is a schematic diagram of an electric energy metering device provided in Embodiment 9 of the present invention, and the electric energy metering device corresponds to the electric energy metering method in the above-mentioned embodiment. The electric energy metering device includes an instantaneous power acquisition module 91, a synthesis operation module 92, an integration module 93, and an electric energy update module 94. The functional modules are described in detail as follows: The instantaneous power acquisition module 91 is used to obtain the instantaneous power information output by the metering chip after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle; A synthesis operation module 92 is used to perform synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle; The integration module 93 is used to perform integration operation on the total instantaneous power of the power grid cycle to obtain the accumulated electric energy; The electric energy updating module 94 is used to update the electric energy value of the electric meter using the accumulated electric energy when the accumulated electric energy reaches a preset pulse constant.

[0064] Optionally, the synthesis operation module 92 includes: A single multi-phase metering chip power acquisition unit is used to obtain the instantaneous power value of each phase of the corresponding single multi-phase metering chip according to the instantaneous power information output by the metering chip if the metering chip is a single multi-phase metering chip; The power calculation unit of a single multi-phase metering chip is used to add the instantaneous power values ​​of each phase to obtain the total instantaneous power of the current power grid cycle.

[0065] Optionally, the synthesis operation module 92 further includes: A multiple single-phase metering chip metering demand unit is used to analyze the multiple single-phase metering chips to obtain metering demand if the metering chip is multiple single-phase metering chips; A metering mode determination unit, used to determine a metering mode according to metering requirements; The metering mode operation unit is used to perform a synthesis operation on the instantaneous power information according to the metering mode to obtain the total instantaneous power of the current power grid cycle.

[0066] Optionally, the integration module 93 includes: A single power effective value calculation unit is used to obtain a preset power grid interruption period, calculate the total instantaneous power according to the power grid interruption period, and obtain a single power effective value; The single power effective value integration unit is used to perform integration operation on the single power effective value of the continuous power grid cycle to obtain the accumulated electric energy.

[0067] Optionally, the power update module 94 includes: The pulse signal output unit is used to output a pulse signal from the metering chip when the accumulated electric energy reaches a preset pulse constant before the accumulated electric energy is used to update the electric energy value of the electric meter; The pulse light response unit is used to input a pulse signal into the electric meter to obtain a pulse light response of the electric meter.

[0068] Optionally, the integration module 93 further includes: The accumulated power acquisition unit is used to acquire the accumulated power corresponding to the accumulated electric energy according to the accumulated electric energy after obtaining the accumulated electric energy; A pulse width calculation unit, used for calculating the accumulated power and the pulse constant to obtain the pulse width; The accumulated electric energy adjustment unit is used to adjust the accumulated electric energy according to the pulse width to obtain the stabilized accumulated electric energy; The electric energy updating unit is used to update the electric energy value of the electric meter using the accumulated electric energy when the accumulated electric energy after stabilization reaches a preset pulse constant.

[0069] Optionally, the integration module 93 further includes: A pulse constant adjustment unit is used to adjust the pulse constant by adopting a pulse doubling strategy after obtaining the accumulated electric energy, so as to obtain a doubled pulse constant; The accumulated electric energy acceleration unit is used to execute the step of acquiring the instantaneous power information output by the metering chip according to the doubled pulse constant to obtain the accumulated electric energy output by the accelerated output; The accumulated electric energy representation unit after acceleration is used to output the electric energy representation of the accumulated electric energy after acceleration if the accumulated electric energy output by acceleration meets the doubled pulse constant.

[0070] For the specific definition of the electric energy metering device, please refer to the definition of the electric energy metering method above, which will not be repeated here. Each module in the above-mentioned electric energy metering device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the electric meter in the form of hardware, or can be stored in the memory in the electric meter in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0071] like Fig.10As shown, it is a schematic diagram of the structure of an electric meter provided in the tenth embodiment of the present invention. The electric meter includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the electric meter is used to provide computing and control capabilities. The memory of the electric meter includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the electric meter is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an electric energy metering method is implemented.

[0072] In one embodiment, an electric meter is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the electric energy metering method in the above embodiment is implemented. For example, Figures 2 to 8 Alternatively, when the processor executes the computer program, the functions of each module / unit in the embodiment of the electric energy metering device are realized, for example Fig. 9 The functions of the instantaneous power acquisition module 91, the synthesis operation module 92, the integration module 93, and the electric energy update module 94 are not described here in detail to avoid repetition.

[0073] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the electric energy metering method in the above embodiment is implemented. Figures 2 to 8 Alternatively, when the computer program is executed by the processor, the functions of each module / unit in the above-mentioned electric energy metering device are realized, for example Fig. 9 The functions of the instantaneous power acquisition module 91, the synthesis operation module 92, the integration module 93, and the power update module 94 are not described here in detail to avoid repetition. The computer-readable storage medium may be non-volatile or volatile.

[0074] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0075] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0076] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.

Claims

1. A method for measuring electric energy, characterized in that: include: After the metering chip updates the effective power and generates a power update interrupt in each power grid cycle, the instantaneous power information output by the metering chip is obtained; Performing a synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle; Integrating the total instantaneous power of the continuous power grid cycle to obtain accumulated electric energy; When the accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter.

2. The electric energy metering method according to claim 1, characterized in that: The synthesizing operation of the instantaneous power information to obtain the total instantaneous power of the current power grid cycle includes: If the metering chip is a single multi-phase metering chip, then according to the instantaneous power information output by the metering chip, the instantaneous power value of each phase corresponding to the single multi-phase metering chip is obtained; The instantaneous power values ​​of each phase are added together to obtain the total instantaneous power of the current power grid cycle.

3. The electric energy metering method according to claim 1, characterized in that: The synthesizing operation of the instantaneous power information to obtain the total instantaneous power of the current power grid cycle includes: If the metering chip is a plurality of single-phase metering chips, the plurality of single-phase metering chips are analyzed to obtain metering requirements; Determine the metering mode according to the metering requirements; The instantaneous power information is synthesized and calculated according to the metering mode to obtain the total instantaneous power of the current power grid cycle.

4. The electric energy metering method according to claim 1, characterized in that: The integrating operation of the total instantaneous power of the continuous power grid cycle to obtain the accumulated electric energy comprises: Obtaining a preset power grid interruption period, and calculating the total instantaneous power according to the power grid interruption period to obtain a single power effective value; The single effective power value of the continuous power grid cycle is integrated to obtain the accumulated electric energy.

5. The electric energy metering method according to claim 1, characterized in that: Before the accumulated electric energy is used to update the electric energy value of the electric meter, the method includes: When the accumulated electric energy reaches a preset pulse constant, the metering chip outputs a pulse signal; The pulse signal is input into an electric meter to obtain a pulse light response of the electric meter.

6. The electric energy metering method according to claim 1, characterized in that: After the accumulated electric energy is obtained, the method further includes: According to the accumulated electric energy, acquiring accumulated power corresponding to the accumulated electric energy; Calculating the accumulated power and the pulse constant to obtain a pulse width; According to the pulse width, the accumulated electric energy is adjusted to obtain a stabilized accumulated electric energy; When the stabilized accumulated electric energy reaches a preset pulse constant, the accumulated electric energy is used to update the electric energy value of the electric meter.

7. The electric energy metering method according to any one of claims 1 to 6, characterized in that: After the accumulated electric energy is obtained, the method further includes: The pulse constant is adjusted by adopting a pulse doubling strategy to obtain a doubled pulse constant; According to the doubled pulse constant, the step of acquiring the instantaneous power information output by the metering chip is performed to obtain the accumulated electric energy of the accelerated output; If the accumulated electric energy outputted by the acceleration meets the doubled pulse constant, the electric energy representation of the accumulated electric energy after the acceleration is outputted.

8. An electric energy metering device, characterized in that: include: The instantaneous power acquisition module is used to obtain the instantaneous power information output by the metering chip after the metering chip updates the effective power and generates a power update interrupt in each power grid cycle; A synthesis operation module, used for performing synthesis operation on the instantaneous power information to obtain the total instantaneous power of the current power grid cycle; An integration module, used for integrating the total instantaneous power of the continuous power grid cycle to obtain accumulated electric energy; The electric energy updating module is used to update the electric energy value of the electric meter using the accumulated electric energy when the accumulated electric energy reaches a preset pulse constant.

9. An electric meter, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the electric energy metering method according to any one of claims 1 to 7 is implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the electric energy metering method according to any one of claims 1 to 7 is implemented.