Research of smart meter design scheme based on IR46

This paper compares the differences between the International Recommendation46 (IR46 for short) and the current national standards for electric energy meter of the accuracy classes, testing requirements, software protection and so on. The national meter adaptability of IR46 is analyzed, and a technical proposal of dual-core smart meter is advanced. This proposal could match the testing and software protection requirements for IR46, and could implementation in China.


I. INTRODUCTION
International Recommendation 46(Referred to as IR46)Active Energy Meter [1] is the International Recommendation for Energy Meters, recently revised by the International Organization of Legal Metrology (OIML). Its content covers the metering requirements, technical requirements and legal management requirements of the energy meter. The IR46 is a mandatory technical regulation for electric energy meters. Once released, all OIML member countries, including China, must adopt and implement it. Therefore, the legal content of China's relevant type evaluation syllabus and verification procedures will be revised simultaneously in the future. The revision of IR46 puts forward higher requirements on metering protection, software upgrade and technical indicators of electric energy meter. However, the existing software and hardware design of smart meter in China is relatively solid and cannot meet the requirements of new standards. At the same time, the long-term operation of the smart energy meter also reveals that the hardware design tends to be perfect. However, Software design still has loopholes, clock battery low-voltage problems occur frequently. There are extended functionality limitations, and needs of the big data era. Therefore, it is necessary to propose a new smart energy meter design scheme to meet the needs of the future implementation of IR46 in China, and to further improve the function of smart energy meter.

II. ADAPTABILITY ANALYSIS OF CURRENT SMART ENERGY METER TECHNOLOGY
Currently, the smart energy meter used in China is designed according to the current standards. It has twoway measurement, information storage and processing, real-time monitoring, advanced fee control, security encryption and other functions to meet the current national electricity price policy, information security, power reliability electrical requirements. However, with the release of the IR46, the legal content of the type evaluation outline and verification procedures related to the energy meter in China will also be complied with the IR46. Further analysis and verification are needed to verify the compliance of the current smart energy meter to the future standard requirements. Therefore, this paper compares IR46 with China's current electric energy meter type evaluation program JJF1245-2010 [2] , and makes applicability analysis for major differences such as accuracy level division, test requirements and measurement performance protection.

A.
Accuracy level and requirements IR46 divides the energy meter level into：A, B, C, D four levels, according to the 4 error limits. They match Level 2, Level 1, 0.5s and 0.2s of the current standard. Different from the expression method of load current characteristic points In/Ib and Imax in JJF1245-2010，in IR46 they are replaced by Ist (starting current), Imin (minimum current), Itr (turning current), and Imax (maximum current), where Itr is the value of the transition current specified by the manufacturer. When the load current value is greater than or equal to this value, the maximum allowable error of the accuracy level corresponding to the meter is within the minimum error limit, which corresponds to the current standard of 0.1Ib (In ). In terms of error limits, the maximum error limit of the energy meter load current in IR46 is slightly higher than the corresponding requirement of JJF1245, and the linear error limit requirement in the small current range is increased. In the early stage, 240 single-phase threephase intelligent electric energy meters from 10 manufacturers were collected to carry out the IR46 bottom test. The test results show that the current smart energy meter can meet the technical requirements of IR46.

B. Test technical requirements
With the increasing complexity of the power environment, the IR46 puts higher demands on the electrical and anti-jamming performance of the energy meter. It improves the original test technical indicators and adds a series of anti-interference test requirements. The IR46 electromagnetic field, starting test and other test indicators require a greater improvement than JJF1245. Secondly, many test methods such as harmonic test, vibration test and high and low temperature test in IR46 are obviously different from the current standard. Finally, IR46 tightens the requirements and test methods for high and low temperature, solar radiation, durability, etc., and strengthens the assessment of the operational stability and reliability of the energy meter in harsh working environments.

C.
Metering performance protection and software upgrade requirement The IR46 proposes that the energy meter should have a means of protecting its own metering performance. The IR46 requires that the metering device of the energy meter be separated from the sub-assembly. The key parts of the metering, whether hardware or software, should not be affected by other parts. The energy meter should support the function of software update. The implementation method can be locally updated or remotely updated via the network But each update should be traceable, and should be able to guarantee the authenticity of the loaded software through technical means [3][4] . The standard clearly states that the energy meter should be able to protect the metering information, and other functions cannot affect the operation of the metering part during the upgrade or operation. At the same time, it is stipulated that all software should have corresponding identifiers, and the power meter is required to display the version number of the running software through the display or the communication interface. In addition to the seal, the software should be protected by software to prevent unauthorized software writing. At present, China's current standards do not have such requirements. Moreover, the existing smart energy meters in China adopt the integrated design, and all adopt the mode of "single MCU+metering chip". The metering chip is responsible for issuing electric energy pulses, and the electric power is accumulated and measured by the MCU. The MCU is also responsible for implementing other functions such as billing, communication, display, and tariff control of the energy meter. The metering related and non-metering related parts are not divided, the software program is relatively solid, and the software upgrade function is not provided. In addition, in order to meet the further functional requirements of the global energy Internet and the powerside release of the smart energy meter, if there is no mature and reliable online software update mechanism, every function update or new rate policy is required, replacement of the energy meter will cost a lot of manpower and resources, and greatly increase the cost of operation and maintenance.
In summary, although the current smart energy meter can meet the technical requirements of the accuracy and various impact tests in the IR46, it does not have the metering performance protection and software upgrade function. In order to meet the requirements of the IR46 standard, this paper proposes a design idea of a dual-core smart electric energy meter based on the original technical level. The measurement part and the management part are independent of each other, which can ensure the accuracy of measurement and the upgrade of software. The design also considers that since the smart energy meter has been in operation for many years, its own technical conditions have been unable to meet the increasing functional requirements, such as clock battery problems [4] , user interaction problems and "multi-table copy" problems. The dual-chip smart energy meter should meet the requirements of IR46, and meet the future electricity price policy, user demand expansion and implementation of new energy policy [5][6][7] .

III. DUAL-CORE SMART ENERGY METER DESIGN BASED ON IR46 REQUIREMENTS
A.
overall framework The micro-current meter is used to sample the output current of the A phase of the three-phase energy meter verification device's power supply without the isolation transformer, and the sampling signal is transmitted to the electric energy recording analyzer. The electric energy re The overall design idea of the dual-core smart energy meter is to independently design the metering part (metering MCU) of the electric energy meter and the management part (management MCU), and to separate the isolated areas in the smart meter, and realize the metering function through the independent MCU. The remaining management-related extensions are implemented through additional MCU. It can be analogized to the operation mode of traditional electric energy meter. The metering part is simple and reliable. It is realized by the metering core and realizes the metering function of the traditional mechanical watch [8][9][10] . The non-metering part is flexible and scalable, which is realized by the management core, similar to the traditional meter reading worker.
As the base meter, the metering part mainly undertakes the energy metering task, stores the power per minute and adds the time scale, and has the functions of time source, pulse indication, total voltage loss and power abnormal event detection. The management part undertakes the management task of the whole table, and is responsible for collecting the electricity quantity information recorded by the measuring core, and performing charging, and also includes tasks such as fee control display, external communication, event recording, data freezing and load control. There is only one communication channel between the two parts for data exchange. The design block diagram of the dual-core smart energy meter is shown in Figure 1.

FIG.1 THE DESIGN BLOCK DIAGRAM OF THE DUAL-CORE SMART ENERGY METER
The division principle of the dual-core intelligent electric energy meter is that the function realized by the measuring core part is simple and reliable, and is responsible for voltage and current sampling, and records the most original electric energy data with time stamp, and this part of the function has no need for modification for a long time. The management core is responsible for functions such as billing, communication, and fee control. The original data required is read from the metering core. This part of the function can be controlled by remote control and does not affect the metering core during upgrade or normal operation work.

B. Power Solution
The dual-core smart energy meter must not only be functionally isolated, but its physical interface, especially the power supply part, should also be isolated to ensure that the power supply part can work normally if the management part is disturbed.
The main power supply of the dual-core smart electric energy meter is provided by the power grid, and the voltage is converted by three voltage regulator modules. The voltage regulator modules are isolated from each other, so that the power supply of the metering module and the management module are independent, without interfere with each other. In the case of power outage, the smart energy meter ensures the accuracy of the clock by powering the RTC module with the clock battery and the super capacitor. And a diode is added to prevent the clock battery from being reversely charged due to the voltage rise after the main power is turned on. The design block diagram of the specific power supply part is shown in Figure 2. The advantage of this scheme is that it not only solves the problem of low-voltage of the current smart energy meter clock battery, but also ensures that the power supply of the metering part is not affected when the power supply of the management part fails, and the normal operation of the metering part is guaranteed [11][12][13] .

2)
Downlink communication scheme The dual-core smart energy meter also takes into account the development requirements of the global energy Internet strategy regarding user interaction. As the terminal of the power grid side, the smart energy meter is directly facing the majority of power users. It is a window for power grid companies to face power users. Real-time data interaction with users is the most direct expression of grid interaction. With the wide application of smart homes and the continuous improvement of the demand for "four-metersreadying" business, a reliable terminal is needed to collect all kinds of information of users, and the innate advantages of smart energy meters determine the conditions for realizing this function. Therefore, the dual-core smart energy meter should have the ability to collect data from the user's smart home, in addition to being able to interact with the user's most basic power information.
Therefore, a downlink standardized communication interface is set in the dual-core electric energy meter.The downlink communication module can be compatible with M-BUS, ZigBee, Bluetooth or WIFI modules to realize real-time two-way interaction with users, and can also meet the new requirements for smart energy meters in the "multi-table collection" service.

3)
Metering core communication scheme For the safety of the metering core data and fault isolation, the data access of the metering core has only three ways: (1) Management core timing acquisition of measurement core and measurement data The SPI communication method is adopted between the metering core and the management core, the communication rate is at least 100 k/bps, and an independent communication protocol is established. The master-slave structure is used for communication, wherein the management core is the master station, the metering core is the slave station, and the establishment and release of the communication link are controlled by the management core.
(2) Reading through an independent local 485 interface In order to ensure the traceability of the legal measurement data, the dual-core smart energy meter leads another 485 interface from the metering core part, which is used for the check or traceback of the legal measurement data after the upgrade failure or functional failure of the management core part.
(3) The electricity information collection system transmits through the management core When the primary station needs to remotely call the metering core basic power consumption data, the electricity information collecting system can read the metering core basic metering data by reading the management core logic device. This data link is completely dependent on the power usage information collection system.

D.
Online upgrade solution When the functional requirements of the energy meter change, the management department can perform a controlled upgrade of the management part of the dualcore smart energy meter through the communication network.
When the functional requirements of the energy meter change, the management department can perform a controlled upgrade of the management part of the dualcore smart energy meter through the communication network. First, the upgrade file of the energy meter to be upgraded is confirmed in a point-to-point manner, and the energy meters to be upgraded are grouped, the multicast upgrade key is negotiated, and the upgrade data is delivered in multicast mode. After the delivery is completed, the upgrade is negotiated. The multicast key is updated and modified to prevent replay attacks. The dual-core smart energy meter can download the new version of the program to the memory, start the upgrade as required, and back up the old version of the program for the recovery when the abnormalities happen during upgrade. After the upgrade, the upgrade result is reported to the primary station, and the new version of the software version number is displayed on the LCD.

Software Reliability
The software reliability of the dual-core electric energy meter is divided into the measurement part and the management part. The separation of the metering core and the management core function enables the software of the dual-core smart energy meter to operate independently. However, consideration should be given to the possible impact of the metering part when the management part of the software changes. Therefore, the software of the management part is erased and upgraded during the verification process, and the accurcy and reliability of the metering part are verified. In addition, the software changes in the management part should be strictly controlled by the technical supervision bureau and the power grid company. The function and reliability should be fully demonstrated before the software changes, to ensure that the software changes after the upgrade do not affect the reliable operation of the dual-core smart energy meter.

IV. CONCLUSION
The article compares the difference between IR46 and China's electric energy meter type evaluation program, and analyzes the current electric energy meter's satisfaction with the IR46 standard.Based on the existing electric energy meter design, a dual-core smart energy meter designed suitable for IR46 is proposed. The program has the following advantages: (1) Legal measurement independence: The legal system and the illegal system of measurement software are independent of each other. The data interaction is realized through standard interfaces.
(2) Traceability of legal measurement data: Regularly freeze the basic energy data, including the positive and negative active total energy, and the fourquadrant reactive total energy. The legal measurement part needs to have an independent communication interface to facilitate the traceability of legal measurement data and the verification of illegal accounting data.
(3) Accuracy and reliability of legal measurement data: Legal measurement data cannot be falsified, and data storage security protection is added to ensure the accuracy and reliability of energy measurement.
(4) Clock security: The clock belongs to the legal measurement part, and the clock requirement can be set, but the clock setting needs to be protected by security authentication and data encryption.