CN114089619A - Intelligent ammeter time correction method and system - Google Patents
Intelligent ammeter time correction method and system Download PDFInfo
- Publication number
- CN114089619A CN114089619A CN202111268508.6A CN202111268508A CN114089619A CN 114089619 A CN114089619 A CN 114089619A CN 202111268508 A CN202111268508 A CN 202111268508A CN 114089619 A CN114089619 A CN 114089619A
- Authority
- CN
- China
- Prior art keywords
- communication module
- electric meter
- built
- intelligent electric
- timing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 47
- 238000012937 correction Methods 0.000 title description 7
- 238000004891 communication Methods 0.000 claims abstract description 129
- 230000008569 process Effects 0.000 claims description 17
- 230000002452 interceptive effect Effects 0.000 claims description 3
- 230000003993 interaction Effects 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 101000623897 Homo sapiens Mucin-12 Proteins 0.000 description 1
- 102100023143 Mucin-12 Human genes 0.000 description 1
- 230000002457 bidirectional effect Effects 0.000 description 1
- 238000013523 data management Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 230000005611 electricity Effects 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 230000002265 prevention Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G04—HOROLOGY
- G04G—ELECTRONIC TIME-PIECES
- G04G7/00—Synchronisation
Abstract
The invention relates to a method and a system for timing an intelligent ammeter, wherein after the intelligent ammeter acquires a communication module parameter set stored by the intelligent ammeter, an internal communication module of the intelligent ammeter sends an NTP timing command to an NTP server according to an NTP period in the communication module parameter set, a timestamp comprising message round-trip delay and module time difference fed back by the NTP server is written into the intelligent ammeter by the internal communication module, and the intelligent ammeter sets a clock per se according to the written timestamp, so that the timing efficiency of the intelligent ammeter and the accuracy of the clock after timing are improved, the metering data and the reported data of the ammeter data collected by a power grid are more reliable and accurate, and the dependence of the ammeter timing work on the timing command issued by a master station is avoided.
Description
Technical Field
The invention relates to the field of electric meters, in particular to a method and a system for timing an intelligent electric meter.
Background
Currently, smart meters have been widely used in power grids, and the development from the conventional power grid to the smart power grid is realized.
In the operation process of the smart grid, the smart meter has a basic electric quantity metering function, and also has a bidirectional data communication function, an electricity stealing prevention function and other intelligent functions. Based on the requirements of data management and metering, accurate and reliable records need to be made on the electric meter data of each intelligent electric meter in the intelligent power grid. Therefore, in order to ensure the reliability and integrity of the recorded meter data, the meter time of each smart meter must be accurately and timely calibrated.
However, in the existing method for timing the smart meter, the master station mainly issues a timing command to the smart meter through the communication channel, which results in high timing cost and low timing efficiency for the smart meter with the communication function, and reduces the clock accuracy of the smart meter in timing.
Disclosure of Invention
The first technical problem to be solved by the present invention is to provide a method for timing an intelligent electric meter in view of the above prior art.
The second technical problem to be solved by the invention is to provide the smart meter timing system for implementing the smart meter timing method.
The technical scheme adopted by the invention for solving the first technical problem is as follows: the intelligent electric meter timing method is characterized by comprising the following steps of 1-5:
step 1, a built-in communication module in an intelligent ammeter acquires a parameter set which is stored in the ammeter and is related to the built-in communication module after the ammeter is electrified; wherein, the parameter set related to the built-in communication module comprises NTP address and NTP period;
step 2, a built-in communication module in the intelligent electric meter sends an NTP timing request to an NTP server according to the NTP period in the acquired parameter set;
step 3, the NTP server sends a timestamp containing message round-trip delay and module time difference to a built-in communication module in the intelligent electric meter;
step 4, writing the received timestamp into the intelligent electric meter by a built-in communication module in the intelligent electric meter;
and 5, setting the clock of the intelligent electric meter according to the written timestamp.
In an improved manner, in the method for timing the smart meter, the process of setting the self clock by the smart meter according to the written timestamp includes the following steps:
step a1, after the MCU of the intelligent electric meter is powered on, resetting is carried out, and the step a2 is carried out;
step a2, the intelligent electric meter judges whether the power supply is electrified:
when the power supply is powered, the step a3 is carried out; otherwise, go to step a 8;
step a3, the built-in communication module sends a communication request to the MCU of the intelligent ammeter, and the MCU judges whether the communication port of the ammeter meets the communication conditions:
when the communication port meets the communication condition, the step a4 is carried out; otherwise, go to step a 9;
step a4, the smart electric meter judges whether the current protocol is an EMC protocol:
when the current rule is about the EMC protocol, the intelligent electric meter analyzes a protocol frame of the EMC protocol, and the step a5 is carried out; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a5, the smart electric meter judges and processes the protocol frame of the EMC protocol analyzed:
when the protocol frame of the EMC protocol is read data, the process proceeds to step a 6; otherwise, go to step a 10;
step a6, the built-in communication module judges whether to acquire communication module parameters from the smart electric meter:
when the communication module parameters are acquired, the step a7 is carried out; otherwise, go to step a 4;
step a7, the smart electric meter judges whether the acquired communication module parameter is the communication module parameter corresponding to the built-in communication module:
when the communication module parameter is the communication module parameter corresponding to the built-in communication module, the intelligent electric meter acquires the NTP address and the NTP period written in the timestamp in the intelligent electric meter, returns the communication module parameter to the built-in communication module, and goes to step a 9; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a8, switching the intelligent electric meter into a power-down working mode and switching to step a 1;
step a9, the intelligent electric meter closes the communication channel;
step a10, the intelligent electric meter sets electric meter information according to the EMC protocol, sets time for the intelligent electric meter according to the data identification of the EMC protocol, and the step a9 is carried out.
In the method for timing the smart electric meter, the communication mode between the built-in communication module and the NTP server is UDP communication.
And improving the time correction method, wherein in the time correction method of the intelligent electric meter, the interactive data between the built-in communication module and the NTP server adopts an NTP protocol.
Further, in the method for timing the smart meter, in step 4, the built-in communication module writes the received timestamp into an EEPROM of the smart meter.
Preferably, in the method for timing the smart meter, the built-in communication module is a GPRS module.
Optionally, in the method for timing the smart electric meter, the built-in communication module is a 4G communication module or a 5G communication module.
The technical scheme adopted by the invention for solving the second technical problem is as follows: the intelligent electric meter timing system for realizing the intelligent electric meter timing method is characterized by comprising the following steps:
the intelligent electric meter is provided with an MCU and a built-in communication module, and the MUC is connected with the built-in communication module;
and the NTP server is in communication connection with the built-in communication module of the intelligent electric meter.
In the smart electric meter timing system, the connection mode between the built-in communication module and the NTP server is UDP communication connection.
Optionally, in the smart electric meter timing system, the built-in communication module is a GPRS module, a 4G communication module, or a 5G communication module.
Compared with the prior art, the invention has the advantages that:
firstly, in the method for timing the smart meter, after the smart meter acquires the communication module parameter set stored by the smart meter, the built-in communication module of the smart meter sends an NTP timing command to the NTP server according to the NTP period in the communication module parameter set, the built-in communication module writes a timestamp comprising message round-trip delay and module time difference fed back by the NTP server into the smart meter, and the smart meter sets a self clock according to the written timestamp, because the built-in communication module of the smart meter and the NTP server adopt NTP protocol for data interaction, the time source of the NTP server comes from an atomic clock, a astronomical table, a satellite or the Internet, an accurate and reliable time source is provided, further, the time correction based on the time source has higher precision, the timing efficiency of the smart meter and the accuracy of the clock after timing are improved, further, metering data and reported data of ammeter data collected by a power grid are more reliable and accurate, and dependence of ammeter timing work on timing instructions issued by a master station is avoided.
Secondly, because the smart meter and the NTP server perform data interaction related to time correction through the NTP protocol, the NTP protocol uses a mature identification mechanism to check whether time-setting information (i.e. time correction information) really comes from the NTP server, and further malicious damage to the NTP server which is responsible for providing time-setting data is prevented.
Drawings
FIG. 1 is a schematic flow chart of a smart meter timing method in an embodiment of the invention;
fig. 2 is a schematic diagram of a smart meter timing system in the embodiment of the invention.
Detailed Description
The invention is described in further detail below with reference to the accompanying examples.
The embodiment provides a smart meter timing method, in particular to a smart meter timing method with a built-in communication module, wherein the built-in communication module adopts a GPRS module. Specifically, referring to fig. 1, the smart meter timing method according to the embodiment includes the following steps 1 to 5:
step 1, a GPRS module in an intelligent ammeter acquires a parameter set which is stored in the ammeter and is related to a built-in communication module after the ammeter is electrified; the parameter set related to the built-in communication module comprises an NTP address and an NTP period, and the parameter set related to the built-in communication module is stored in an EEPROM of the electric meter;
step 2, a GPRS module in the intelligent electric meter sends an NTP timing request to an NTP server according to the NTP period in the acquired parameter set; the communication mode between the GPRS module and the NTP server is UDP communication; moreover, the interactive data between the GPRS module and the NTP server adopts NTP protocol;
step 3, the NTP server sends a timestamp containing message round-trip delay and module time difference to a GPRS module in the intelligent electric meter;
for example, assuming that the NTP timing request sent by the GPRS module to the NTP server in step 2 includes "time T1" that needs timing, the current time at the NTP server is "time T2", and then the NTP server calculates the module time difference included in the timestamp as Δ T, where Δ T is T2-T1;
step 4, the GPRS module in the intelligent electric meter writes the received timestamp into the intelligent electric meter; the GPRS module writes the received time stamp into an EEPROM of the intelligent electric meter;
and 5, setting the clock of the intelligent electric meter according to the written timestamp. The process of setting the self clock by the smart meter according to the written timestamp in the embodiment includes the following steps a1 to a 10:
step a1, after the MCU of the intelligent electric meter is powered on, resetting is carried out, and the step a2 is carried out;
step a2, the intelligent electric meter judges whether the power supply is electrified:
when the power supply is powered, the step a3 is carried out; otherwise, go to step a 8;
step a3, the GPRS module in the intelligent ammeter sends a communication request to the MCU of the intelligent ammeter, and the MCU judges whether the communication port of the ammeter meets the communication condition:
when the communication port meets the communication condition, the step a4 is carried out; otherwise, go to step a 9;
step a4, the smart electric meter judges whether the current protocol is an EMC protocol:
when the current rule is about the EMC protocol, the intelligent electric meter analyzes a protocol frame of the EMC protocol, and the step a5 is carried out; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a5, the smart electric meter judges and processes the protocol frame of the EMC protocol analyzed:
when the protocol frame of the EMC protocol is read data, the process proceeds to step a 6; otherwise, go to step a 10;
step a6, the GPRS module judges whether to acquire communication module parameters from the intelligent electric meter:
when the communication module parameters are acquired, the step a7 is carried out; otherwise, go to step a 4;
step a7, the smart electric meter judges whether the acquired communication module parameter is the communication module parameter corresponding to the GPRS module:
when the communication module parameter is the communication module parameter corresponding to the GPRS module, that is, the acquired communication module parameter is the GPRS parameter, the smart meter acquires the NTP address and the NTP period written in the timestamp in the smart meter, returns the communication module parameter to the GPRS module, and proceeds to step a 9; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a8, switching the intelligent electric meter into a power-down working mode and switching to step a 1;
step a9, the intelligent electric meter closes the communication channel;
step a10, the intelligent electric meter sets electric meter information according to the EMC protocol, sets time for the intelligent electric meter according to the data identification of the EMC protocol, and the step a9 is carried out.
Of course, in an actual application process, the built-in communication module in the smart meter of this embodiment may also adopt a 4G communication module or a 5G communication module as needed.
Referring to fig. 2, the embodiment further provides a smart meter timing system for implementing the smart meter timing method. Specifically, the smart meter timing system comprises at least one smart meter 1 and an NTP server 2, wherein the smart meter 1 is provided with an MCU11 and a built-in communication module 12, and the MUC11 is connected with the built-in communication module 12; the NTP server 2 is in communication connection with the built-in communication module 11 of the smart meter 1, and specifically, the built-in communication module 11 is in UDP communication connection with the NTP server 2. The built-in communication module 11 may be a GPRS module, a 4G communication module, or a 5G communication module according to practical application requirements.
Although preferred embodiments of the present invention have been described in detail hereinabove, it should be clearly understood that modifications and variations of the present invention are possible to those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims (10)
1. The intelligent electric meter timing method is characterized by comprising the following steps of 1-5:
step 1, a built-in communication module in an intelligent ammeter acquires a parameter set which is stored in the ammeter and is related to the built-in communication module after the ammeter is electrified; wherein, the parameter set related to the built-in communication module comprises NTP address and NTP period;
step 2, a built-in communication module in the intelligent electric meter sends an NTP timing request to an NTP server according to the NTP period in the acquired parameter set;
step 3, the NTP server sends a timestamp containing message round-trip delay and module time difference to a built-in communication module in the intelligent electric meter;
step 4, writing the received timestamp into the intelligent electric meter by a built-in communication module in the intelligent electric meter;
and 5, setting the clock of the intelligent electric meter according to the written timestamp.
2. The method for timing the smart meter according to claim 1, wherein the process of setting the self clock by the smart meter according to the written timestamp comprises the following steps:
step a1, after the MCU of the intelligent electric meter is powered on, resetting is carried out, and the step a2 is carried out;
step a2, the intelligent electric meter judges whether the power supply is electrified:
when the power supply is powered, the step a3 is carried out; otherwise, go to step a 8;
step a3, the built-in communication module sends a communication request to the MCU of the intelligent ammeter, and the MCU judges whether the communication port of the ammeter meets the communication conditions:
when the communication port meets the communication condition, the step a4 is carried out; otherwise, go to step a 9;
step a4, the smart electric meter judges whether the current protocol is an EMC protocol:
when the current rule is about the EMC protocol, the intelligent electric meter analyzes a protocol frame of the EMC protocol, and the step a5 is carried out; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a5, the smart electric meter judges and processes the protocol frame of the EMC protocol analyzed:
when the protocol frame of the EMC protocol is read data, the process proceeds to step a 6; otherwise, go to step a 10;
step a6, the built-in communication module judges whether to acquire communication module parameters from the smart electric meter:
when the communication module parameters are acquired, the step a7 is carried out; otherwise, go to step a 4;
step a7, the smart electric meter judges whether the acquired communication module parameter is the communication module parameter corresponding to the built-in communication module:
when the communication module parameter is the communication module parameter corresponding to the built-in communication module, the intelligent electric meter acquires the NTP address and the NTP period written in the timestamp in the intelligent electric meter, returns the communication module parameter to the built-in communication module, and goes to step a 9; otherwise, the intelligent electric meter terminates the setting process of the clock of the intelligent electric meter;
step a8, switching the intelligent electric meter into a power-down working mode and switching to step a 1;
step a9, the intelligent electric meter closes the communication channel;
step a10, the intelligent electric meter sets electric meter information according to the EMC protocol, sets time for the intelligent electric meter according to the data identification of the EMC protocol, and the step a9 is carried out.
3. The smart meter timing method according to claim 1, wherein the communication mode between the built-in communication module and the NTP server is UDP communication.
4. The smart meter timing method according to claim 1, wherein the interactive data between the built-in communication module and the NTP server adopts NTP protocol.
5. The method for timing the smart meter according to claim 1, wherein in step 4, the built-in communication module writes the received time stamp into an EEPROM of the smart meter.
6. The method for timing the smart meter according to claim 1, wherein the built-in communication module is a GPRS module.
7. The smart meter timing method according to any one of claims 1-5, wherein the built-in communication module is a 4G communication module or a 5G communication module.
8. The smart meter timing system for implementing the smart meter timing method according to any one of claims 1 to 7, comprising:
at least one intelligent electric meter (1) which is provided with an MCU (11) and a built-in communication module (12), wherein the MUC (11) is connected with the built-in communication module (12);
and the NTP server (2) is in communication connection with the built-in communication module (11) of the intelligent electric meter (1).
9. The system according to claim 8, wherein the built-in communication module (11) is connected with the NTP server (2) in a UDP communication mode.
10. The system according to claim 8, wherein the built-in communication module (11) is a GPRS module, a 4G communication module or a 5G communication module.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111268508.6A CN114089619A (en) | 2021-10-29 | 2021-10-29 | Intelligent ammeter time correction method and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111268508.6A CN114089619A (en) | 2021-10-29 | 2021-10-29 | Intelligent ammeter time correction method and system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114089619A true CN114089619A (en) | 2022-02-25 |
Family
ID=80298173
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111268508.6A Pending CN114089619A (en) | 2021-10-29 | 2021-10-29 | Intelligent ammeter time correction method and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114089619A (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1815146A (en) * | 2005-02-05 | 2006-08-09 | 上海自来水市北科技有限公司 | Wireless long-distance meter-reading system |
CN101718855A (en) * | 2009-11-24 | 2010-06-02 | 深圳市科陆电子科技股份有限公司 | Time calibrating method and system thereof for ammeter calibration |
US20120092184A1 (en) * | 2010-10-18 | 2012-04-19 | Trilliant Incorporated | Method for Synchronizing Meter Clocks in a Network |
CN102656923A (en) * | 2009-10-08 | 2012-09-05 | 阿尔卡特朗讯 | Prevention of congestion at radio access in a mobile or wireless communication system |
JP2014135559A (en) * | 2013-01-08 | 2014-07-24 | Chugoku Electric Power Co Inc:The | Data collection system of smart meter |
CN110166159A (en) * | 2019-05-24 | 2019-08-23 | 南方电网科学研究院有限责任公司 | One kind being based on GPRS network clock synchronization, electric energy meter time synchronization method and system |
CN110677212A (en) * | 2019-10-30 | 2020-01-10 | 武汉慧联无限科技有限公司 | Time synchronization method, device and system and computer storage medium |
-
2021
- 2021-10-29 CN CN202111268508.6A patent/CN114089619A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1815146A (en) * | 2005-02-05 | 2006-08-09 | 上海自来水市北科技有限公司 | Wireless long-distance meter-reading system |
CN102656923A (en) * | 2009-10-08 | 2012-09-05 | 阿尔卡特朗讯 | Prevention of congestion at radio access in a mobile or wireless communication system |
CN101718855A (en) * | 2009-11-24 | 2010-06-02 | 深圳市科陆电子科技股份有限公司 | Time calibrating method and system thereof for ammeter calibration |
US20120092184A1 (en) * | 2010-10-18 | 2012-04-19 | Trilliant Incorporated | Method for Synchronizing Meter Clocks in a Network |
JP2014135559A (en) * | 2013-01-08 | 2014-07-24 | Chugoku Electric Power Co Inc:The | Data collection system of smart meter |
CN110166159A (en) * | 2019-05-24 | 2019-08-23 | 南方电网科学研究院有限责任公司 | One kind being based on GPRS network clock synchronization, electric energy meter time synchronization method and system |
CN110677212A (en) * | 2019-10-30 | 2020-01-10 | 武汉慧联无限科技有限公司 | Time synchronization method, device and system and computer storage medium |
Non-Patent Citations (3)
Title |
---|
王水平等: "《开关电源原理与应用设计实验教程》", 28 February 2019 * |
王辉: "《自然计算与网络状态认知和流量控制》", 31 August 2016, 西安电子科技大学出版社 * |
路宏敏等: "《工程电磁兼容 第3版》", 31 August 2019 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101202545B (en) | High-accuracy data receiving time service instrument | |
CA2688750A1 (en) | Device time adjustment for accurate data exchange | |
KR20200083533A (en) | Clock metering method of watt hour meter, device, computer equipment and storage medium | |
US20100188255A1 (en) | Relative time system | |
CN103092062B (en) | Method and system used for real-time clock chip accuracy adjustment | |
CN110928176B (en) | Multifunctional time service equipment supporting multiple time service technologies | |
CN109828131B (en) | Method for recording occurrence events by intelligent electric meter | |
CN101043253A (en) | Process for obtaining high-precision time | |
CN102621954A (en) | Self-adaptive multi-signal-source time synchronization card device for smart grid and message analysis system | |
CN100574217C (en) | A kind of method and system of adding up the veneer reliability index | |
CN202486606U (en) | Adaptive multi-signal-source timing equipment in intelligent power grid and report analysis system | |
CN113960413A (en) | Time synchronization method for collecting unit and collecting unit in fault indicator | |
US20210271693A1 (en) | Synchronization system and method for substation monitoring backend database, scd, and rcd | |
CN108491432B (en) | Electric power system accumulated quantity storage and extraction method based on message abstract, electronic equipment and storage medium | |
CN114089619A (en) | Intelligent ammeter time correction method and system | |
CN208421826U (en) | A kind of multichannel is based on FPGA high-accuracy data collection card | |
CN106455039B (en) | Communication terminal, network and the method for clock synchronization precision are improved in a kind of power distribution network | |
CN104597964A (en) | Time server | |
CN213754464U (en) | IRIGB millisecond pulse generating circuit | |
CN110597120A (en) | Acquisition terminal and method based on power line carrier | |
CN212905227U (en) | Recording fault finding device | |
CN103092180B (en) | A kind of locomotive brake data syn-chronization dump method and data memory transfer device | |
CN116938380B (en) | Time scale management method, device, computer equipment and time scale manager | |
CN103093332A (en) | Contract charging device with reminding mechanism | |
CN103699103A (en) | Method for sequentially recording events in distributed control system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20220225 |