Power consumption meter terminal
By using a clock compensation module in the power consumption metering terminal to receive reference clock updates and adjust the local clock, the problem of local clock drift is solved, resulting in more accurate timestamps, reduced network traffic, and improved accuracy of power consumption data and network efficiency.
Patent Information
- Application Number
- CN202480021601.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-03-31
- Filing Date
- 2024-03-27
- Publication Date
- 2025-11-18
AI Technical Summary
The local clock of the power consumption metering terminal is prone to drift over time, resulting in inaccurate timestamps, which affects the accuracy of load curve marking and diagnostic data. Furthermore, the existing technology that relies on grid frequency correction is no longer reliable.
A clock compensation module is used to receive time updates from an external reference clock, record and analyze errors, adjust the local clock using an approximation function to keep it synchronized with the reference clock, reduce errors, and periodically update the local clock.
This has resulted in more accurate local clocks for power consumption metering terminals, reduced network traffic and the number of devices, improved the accuracy of load curves and diagnostic data, and reduced network traffic.
Smart Images

Figure CN120981785A_ABST
Abstract
Description
Technical Field
[0001] This disclosure pertains to the field of electricity consumption metering endpoints (e.g., electricity meters) for measuring electricity consumption in places such as residential and commercial premises. In particular, this disclosure relates to electricity consumption metering endpoints with clock compensation modules. Background Technology
[0002] An electricity consumption metering terminal (e.g., an electricity meter, also known in the art as a power meter, electronic meter, or electrical meter) is a device that measures the electrical power consumed by one or more electric devices over a period of time, such as in a residential or commercial premises.
[0003] Electricity meters are typically installed at a location for billing and monitoring consumption. In some examples, the meter can be read manually and periodically to determine the level of electricity consumption. In other examples, advanced meters, referred to in the art as “smart meters,” can be configured to communicate with utility providers, for example wirelessly, to provide electricity consumption information and / or receive billing information and / or control signals.
[0004] Electricity meter usage time is used to monitor usage and as a timestamp for diagnostic and billing-related events. The accuracy of the clock maintained by the clock source in the meter can easily drift over time because the clock source is typically a crystal or crystal oscillator, which will have inherent errors from the nominal value as well as errors due to temperature and component aging.
[0005] Previously, electricity meters used the grid line frequency as a time source to periodically calculate and compensate for errors in their local clocks. This has been widely abandoned because grid operators have begun to deviate from the practice of keeping their line frequencies closely synchronized with an accurate reference time source. Summary of the Invention
[0006] The inventors have recognized the need for an electricity consumption metering terminal that can maintain a more accurate clock over time relative to a reference clock.
[0007] When a time adjustment occurs, the meter corrects its time, and in doing so, it marks the load profile interval as long or short based on the direction of the time adjustment, and ends the current demand interval and begins a new one, ensuring that no demand maximum is created due to an artificially long interval, although this action may not record a truly new maximum. The marking of load profile intervals and potentially missed demand maximums has an impact on utilities, and therefore minimizing the frequency of this occurrence is beneficial. The usefulness of diagnostic and other event data is also beneficial if the accuracy of the timestamps associated with them is more rigorous.
[0008] According to a first aspect of this disclosure, an electricity consumption metering terminal is provided, comprising: a local clock; and a clock compensation module configured to: receive a plurality of reference clock time updates output by a reference clock external to the electricity consumption metering terminal; record the time of the local clock at each of the plurality of reference clock time updates received; and determine an approximate function of the evolution of the error between the local clock and the reference clock over time using the plurality of reference clock time updates and the time of the local clock; wherein the clock compensation module is further configured to perform a local clock update process, wherein the clock compensation module is further configured to: obtain the time of the local clock; determine the error between the local clock and the reference clock using the time of the local clock and the approximate function; calculate a compensation time using (i) the time of the local clock and (ii) the error between the local clock and the reference clock; and transmit at least one clock configuration message based on the compensation time to the local clock; wherein the local clock is configured to output a time update based on at least one clock configuration message.
[0009] Advantageously, the electricity consumption metering terminal is able to maintain a more accurate local clock.
[0010] Periodic updates of the local clock, performed by applying adjustments based on the calculated error, can push the error between the local clock and the reference clock to zero. This minimizes clock drift in the instrument between reference clock updates and reduces the frequency at which reference clock updates need to occur. This directly reduces the amount of network traffic consumed by the transmission of reference clock updates. It also reduces the number of network devices that require a reference clock, such as GPS modules.
[0011] At least one clock configuration message may consist of only a single clock configuration message, which includes compensation time.
[0012] At least one clock configuration message includes only a single clock configuration message, which includes instructions to speed up or slow down the local clock by a time value corresponding to the error between the local clock and the reference clock.
[0013] At least one clock configuration message includes multiple clock configuration messages. The clock compensation module is configured to continuously transmit multiple clock configuration messages. Each of the multiple clock configuration messages includes an instruction to speed up or slow down the local clock by a time value. The sum of the time values of each of the multiple clock configuration messages is the error between the local clock and the reference clock.
[0014] The clock compensation module can be configured to receive one or more additional reference clock time updates output by the reference clock, and to use the multiple reference clock time updates and one or more additional reference clock time updates to adjust the approximation function.
[0015] The power consumption metering terminal may include: a communication unit configured to receive multiple reference clock time updates; and a metering unit, wherein the metering unit includes a metering application configured to associate (i) power-related data associated with power consumed in the power distribution system with (ii) the time updates to generate time-based power-related data; wherein the communication unit may also be configured to transmit time-based power-related data to one or more external devices.
[0016] The metering unit may include a local clock and a clock compensation module.
[0017] Alternatively, the communication unit may include a local clock and a clock compensation module.
[0018] The metering unit may include: an interface to a power distribution system, which associates analog power-related data with the power consumed in the power distribution system; an analog-to-digital conversion circuit for converting the analog power-related data into digital power-related data; and a processor configured to process the digital power-related data to generate power-related data and provide the power-related data to the metering application.
[0019] The communication unit can be configured to transmit time-based power-related data to one or more external devices via a mesh-based communication network.
[0020] The clock compensation module can be configured to periodically receive reference clock time updates.
[0021] The clock compensation module can be configured to periodically perform a local clock update process.
[0022] According to another aspect of this disclosure, a mesh-based communication network is provided, comprising: an electricity consumption metering terminal as described herein; and at least one network device, wherein the network device in the at least one network device includes a reference clock.
[0023] The network device that includes a reference clock can be another power consumption metering terminal. Alternatively, the network device that includes a reference clock is a server.
[0024] According to another aspect of this disclosure, a method for updating a local clock on an electricity consumption metering terminal is provided. The method is performed by a clock compensation module on the electricity consumption metering terminal and includes: receiving a plurality of reference clock time updates output by a reference clock external to the electricity consumption metering terminal; recording the time of the local clock at each of the plurality of reference clock time updates received; determining an approximate function of the evolution of the error between the local clock and the reference clock over time using the plurality of reference clock time updates and the time of the local clock; and performing a local clock update process by: obtaining the time of the local clock; determining the error between the local clock and the reference clock using the time of the local clock and the approximate function; calculating a compensation time using (i) the time of the local clock and (ii) the error between the local clock and the reference clock; and transmitting at least one clock configuration message based on the compensation time to the local clock.
[0025] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided, comprising at least one instruction that, when executed by at least one processor, causes the at least one processor to perform any method performed by the clock compensation module described herein.
[0026] Instructions may be provided on one or more carriers. For example, one or more non-transient memories may be present, such as EEPROM (e.g., flash memory), magnetic disks, CD-ROMs or DVD-ROMs, programmable memories such as read-only memories (e.g., for firmware), one or more transient memories (e.g., RAM), and / or data carriers such as optical or electrical signal carriers. The memory / multiple memories may be integrated into and / or separated from the corresponding processing chip. Code (and / or data) used to implement embodiments of this disclosure may include source code, object code, or executable code in a conventional programming language such as C (interpreted or compiled), or assembly code, code for setting up or controlling an ASIC (Application-Specific Integrated Circuit) or FPGA (Field-Programmable Gate Array), or code in a hardware description language.
[0027] The above overview is intended to be exemplary only and not restrictive. This disclosure includes one or more corresponding aspects, embodiments, or features, individually or in various combinations, whether specifically stated (including claimed) in such combination or individually. It should be understood that features defined above according to any aspect of this disclosure or features relating below to any particular embodiment of this disclosure may be used individually or in combination with any other defined features in any other aspect or embodiment, or to form further aspects or embodiments of this disclosure. Attached Figure Description
[0028] These and other aspects of this disclosure will now be described by way of example only with reference to the accompanying drawings, in which:
[0029] Figure 1 A mesh network is shown;
[0030] Figure 2a A schematic block diagram of a clock compensation module and a local clock arranged according to an example is depicted.
[0031] Figure 2b A schematic block diagram of a clock compensation module and a local clock arranged according to another example is depicted.
[0032] Figure 3 A schematic block diagram of an electricity consumption metering terminal according to an embodiment of the present disclosure is depicted;
[0033] Figure 4 A schematic block diagram depicting an electricity consumption metering terminal according to another embodiment of the present invention;
[0034] Figure 5 This is a flowchart illustrating a method that can be performed by an electricity consumption metering terminal;
[0035] Figure 6 The waveform of an example linear equation approximating the error between the local clock and the reference clock is shown;
[0036] Figure 7 This is a flowchart illustrating the local clock update process; and
[0037] Figure 8 This demonstrates how to use the local clock's time and an approximation function to determine the error between the local clock and the reference clock. Detailed Implementation
[0038] Figure 1 A mesh network 102 comprising multiple power consumption metering terminals 106 is illustrated. It should be understood that the number of power consumption metering terminals 106 shown in the mesh network 102 is merely an example. The mesh network 102 can be an advanced metering infrastructure (AMI) or a radio frequency (RF) network. Other embodiments may be implemented outside of an AMI system.
[0039] In one example, mesh network 102 is associated with a distribution network to transmit measurements or other data obtained in the distribution network. In this example, multiple electricity consumption metering terminals 106 include meters implemented to measure various operational characteristics of the distribution network and transmit collected data to server 104 via mesh network 102.
[0040] Server 104 receives data streams or message streams from multiple power consumption metering terminals 106. Server 104 can process the collected data or enable the collected data to be processed for various applications.
[0041] Each power consumption metering terminal 106 in the mesh network 102 can communicate with other devices in the mesh network 102 (e.g., server 104 and other power consumption metering terminals) via wired and / or wireless communication channels. Similarly, server 104 can communicate with one or more power consumption metering terminals 106 via wired and / or wireless communication channels.
[0042] One or more of the multiple power consumption metering terminals 106 may include a reference clock 108. This is in Figure 1 The diagram shows a power consumption metering terminal 106a including a reference clock 108. Alternatively or additionally, server 104 may include the reference clock 108. The reference clock 108 is configured to provide multiple reference clock time updates in an accurate and stable manner (e.g., periodically).
[0043] According to embodiments of this disclosure, the clock compensation module 206 of the power consumption metering terminals 106b-106e uses (i) multiple reference clock time updates output by the reference clock 108, and (ii) the time of the local clock 204 receiving each of the multiple reference clock time updates, to determine an approximate function of the evolution of the error between the local clock and the reference clock over time. This is referred to below. Figure 5 and Figure 6 To describe in more detail.
[0044] Then, the clock compensation module 206 of the power consumption metering terminal 106b-106e can perform a local clock update process based on the local clock time and an approximation function, and transmit at least one clock configuration message to the local clock 204 based on the compensation time. The at least one clock configuration message configures the local clock 204 to output a time update based on the at least one clock configuration message.
[0045] Figure 2a A schematic block diagram depicts a local clock 204 and a clock compensation module 206 arranged according to an example, wherein the local clock 204 and the clock compensation module 206 are components of a single processor 202, which may be, for example, a microprocessor or a microcontroller.
[0046] Figure 2b A schematic block diagram of a local clock 204 and a clock compensation module 206 according to another example arrangement is depicted, wherein the local clock 204 is external to the processor 222 including the clock compensation module 206. In this example arrangement, the local clock 204 may be provided on an application-specific integrated circuit (IC). In this example arrangement, the local clock 204 and the clock compensation module 206 may communicate via an I2C or SPI bus or via a UART.
[0047] In both example arrangements, clock compensation module 206 is configured to receive a reference clock time update output by reference clock 108. Clock compensation module 206 is also configured to receive a local clock time update from local clock 204. Clock compensation module 206 is configured to transmit at least one clock configuration message to local clock 204. Local clock 204 is configured to receive at least one clock configuration message and output a time update based on at least one clock configuration message.
[0048] The functions of the clock compensation module 206 described herein can be implemented as code (software) stored in the memory of an electricity consumption metering terminal including one or more storage media, and arranged to execute on a processor 202, 222 including one or more processing units. Alternatively, it is not excluded that some or all of the functions of the clock compensation module 206 may be implemented in dedicated hardware circuitry (e.g., ASIC, simple circuits, gates, logic, and / or configurable hardware circuitry (e.g., FPGA)).
[0049] Figure 3 and Figure 4 This is a schematic block diagram of a power consumption metering terminal (e.g., one of power consumption metering terminals 106b-e) excluding the reference clock 108.
[0050] like Figure 3 and Figure 4 As shown, the power consumption metering terminal 106 includes a communication unit 302 and a metering unit 304.
[0051] The communication unit 302 enables wired and / or wireless communication between the power consumption metering terminal and other power consumption metering terminals and / or the server 104. Specifically, the communication unit 302 is arranged to receive reference clock time updates output by the reference clock 108 (which is external to the power consumption metering terminal 106).
[0052] Communication unit 302 may allow receiving radio frequency transmissions from other power consumption metering terminals and / or server 104. Communication unit 302 may also allow radio frequency transmissions to be sent to other power consumption metering terminals and / or server 104.
[0053] Alternatively or additionally, communication unit 302 may allow communication with other power consumption metering terminals and / or servers 104 via power line communication (PLC) on the power lines of the power distribution network.
[0054] Alternatively or additionally, communication unit 302 may allow communication with other power consumption metering terminals and / or servers 104 via point-to-point wireless (e.g., cellular) communication.
[0055] Metering unit 304 is configured to receive analog power-related data associated with electricity consumed in the distribution network. The power-related data may include measured voltage, current, and / or power signals. Specifically, the power-related data may include one or more of the following: (i) a load-side voltage signal indicating the voltage across a load (which may be a residential load, such as a house); (ii) a 'phase C' current flowing to the load; and (iii) a 'phase A' current flowing to the load. The power-related data may include RMS voltage and / or current signals.
[0056] Metering unit 304 includes an analog-to-digital converter (ADC) 308 that converts analog power-related data into digital power-related data. The digital power-related data is output by the ADC 308 to a processor (e.g., a digital signal processor) 308, which is configured to process the digital power-related data and output the processed digital power-related data (shown as "calculated value").
[0057] The metering unit 304 may also include a serial port 310 to allow optical communication between the power consumption metering terminal and the portable computing device during installation or maintenance (e.g., performing billing data readout, usage time (TOU) readout and modification, billing cycle reset, register and curve reset, parameter readout and modification, etc.).
[0058] The metering unit 304 may also include an input device 312 (e.g., a button) to allow user input to be received, for example, from a utility provider’s customer or maintenance technician.
[0059] The metering unit 304 may also include a display device (e.g., an LCD display device) 314 for outputting data (e.g., power consumption information).
[0060] like Figure 3 and Figure 4 As shown, the metering unit 304 includes a metering application 306.
[0061] Metering application 306 is configured to receive processed digital power-related data and time information from processor 308, and use the processed digital power-related data and time information to generate time-based power-related data. The time-based power-related data may include one or more of the following: (i) usage time information; (ii) load curves; (iii) event log information; and (iv) demand information.
[0062] Usage time information can include a utility configuration calendar that defines a daily schedule so that energy and demand values are composed of configured time periods throughout the day, allowing for different rates and penalties to be charged based on the time of day for usage.
[0063] Load curves can include a set of configured metrics accumulated over a configured interval length. At the end of the interval, the resulting value of each metric is stored in memory. Memory is allocated such that a series of these interval values can be stored. The data is then retrieved periodically and can be used to verify the integrity of billing sum reads (by summing interval values for the same time period) and to present trends of any given metric over time for internal use within the utility or to inform end customers.
[0064] Electricity consumption metering terminals (such as electricity meters) can identify a variety of events. These events may be related to electrical services (e.g., power loss and restoration, voltage dips, voltage rises, current overloads, etc.), metering / communication infrastructure (e.g., the time set in the meter, the time of a meter configuration change), and / or diagnostic information within the meter (e.g., detected memory errors). Any of these types of events can be configured to be logged in an event log when experienced. Event log information typically records what type of event occurred, the date / time of the event, and some additional parameters that may better describe the instance (e.g., which phase of a 3-phase meter experienced a voltage dip).
[0065] Demand information can include one or more electrical energy units (active, reactive, and / or apparent) accumulated over a configured interval length. At the end of the interval length, the accumulated electrical energy is divided by the interval length to provide the average power supply over that interval, which is referred to as the demand. This demand value can then be compared to a list of maximum demand values for that metric held by the meter. If the new value is one of the new maximum values, it can be inserted into the list along with the date / time for that interval.
[0066] The functionality of the metering application 306 described herein can be implemented as code (software) stored in the memory of an electricity consumption metering terminal comprising one or more storage media, and arranged to execute on a processor comprising one or more processing units. The processor can be, for example, a microprocessor or a microcontroller. Alternatively, it is not excluded that some or all of the functionality of the metering application 306 may be implemented in dedicated hardware circuitry (e.g., ASICs, simple circuits, gates, logic, and / or configurable hardware circuitry (e.g., FPGAs)).
[0067] like Figure 3 and Figure 4 As shown, metering application 306 can be coupled to serial port 310 to allow communication of parameters and data between metering application 306 and serial port 310. Metering application 306 can be coupled to input device 312 to allow metering application 306 to receive input (e.g., button presses). Metering application 306 can be coupled to display device 314 for outputting visual data (e.g., display values) to display device 314.
[0068] It should be understood that metering application 306 requires accurate time information in order to accurately generate the time-based power-related data mentioned above.
[0069] Figure 3 A schematic block diagram of an electricity consumption metering terminal 106 according to some embodiments of the present disclosure is depicted. Specifically, Figure 3 This illustrates how a local clock 204 and a clock compensation module 206 can be implemented on the metering unit 304. That is, the local clock 204 and the clock compensation module 206 can be components of the metering unit 304. In these embodiments, processors 202 and 222 can also implement the functions of the metering application 306. Alternatively, in addition to processors 202 and 222, a separate processor can be provided for performing the functions of the metering application 306. Figure 3 In one embodiment, the communication unit 302 is configured to receive a reference clock time update output by the reference clock 108 and provide the reference clock time update to the clock compensation module 206 on the metering unit 304. The local clock 204 on the metering unit 304 is configured to transmit a compensated time update (based on at least one clock configuration message received from the clock compensation module 206) to the metering application 306.
[0070] Figure 4 A schematic block diagram of an electricity consumption metering terminal 106 according to other embodiments of the present disclosure is depicted. In particular, Figure 4 This illustrates how a local clock 204 and a clock compensation module 206 can be implemented on communication unit 302. That is, the local clock 204 and the clock compensation module 206 can be components of communication unit 302. In these embodiments, communication unit 302 is arranged to receive a reference clock time update output by reference clock 108, and the local clock 204 on communication unit 302 is arranged to send a compensated time update (based on at least one clock configuration message received from clock compensation module 206) to metering application 306.
[0071] Figure 5 This is a flowchart illustrating a method 500 that can be executed by the clock compensation module 206.
[0072] At step S502, the clock compensation module 206 initializes the integer value so that i=1.
[0073] At step S504, the clock compensation module 206 receives the reference clock time update Clock_Ref output by the reference clock 108. iThe clock compensation module 206 associates the reference clock time update received in step S504 with the current value of the integer value i held in the memory of the power consumption metering terminal by the clock compensation module 206. It will be understood that the first reference clock time update received by the clock compensation module 206 is denoted as Clock_Ref1, and the subsequently received reference clock time updates will be Clock_Ref2, Clock_Ref3, etc.
[0074] In step S506, when the reference clock time update Clock_Ref is received in step S504... i At the same time, the clock compensation module 206 records the time Clock_Local of the local clock 204. i As described above, the clock compensation module 206 is configured to receive local clock time updates from the local clock 204.
[0075] In step S508, the clock compensation module 206 calculates the reference clock time update Clock_Ref received in step S504. i Error between the time recorded at step S506 and the local clock 204 i (For example, in seconds). Specifically, the error can be calculated as:
[0076] Error i = Clock_Local i – Clock_Ref i
[0077] In step S510, the clock compensation module 206 will calculate the error. i and the local clock 204's time Clock_Local i It is stored in the memory of the electricity consumption metering terminal.
[0078] At step S512, the clock compensation module 206 determines whether a reference clock time update has been received previously (i.e., if i ≥ 2). If the clock compensation module 206 determines that a reference clock time update has not been received previously (i.e., i = 1), the clock compensation module 206 increments the integer value i in step S514, and when a second reference clock time update Clock_Ref2 is received, method 500 loops back to step S504.
[0079] If the clock compensation module 206 determines that a reference clock time update has been previously received (i.e., i≥2), then method 500 proceeds to step S516, where the clock compensation module 206 determines or modifies an approximate function of the error's evolution over time.
[0080] Once two reference clock time updates are received, two points are stored (each point corresponds to the error). i and the local clock 204's time Clock_Local i These points can be used to form a linear equation, which approximates the error at any given future time point, for example, using linear approximation or curve fitting techniques. Specifically, when i=2 at step S512, the clock compensation module 206 determines the approximation function.
[0081] Once three or more reference clock time updates have been received and three or more points (each point corresponding to an error) have been stored... i and the local clock 204's time Clock_Local i This allows for the formulation of higher-order equations to account for errors, such as linear approximations or curve fitting techniques. Specifically, when i ≥ 3 at step S512, the clock compensation module 206 modifies the previously established approximation function. With each new (e.g., periodic) update from the reference clock 108, the used equations can be recalculated using the new updated data points and any stored historical data points.
[0082] Figure 6 This shows the approximation error at any given point in the future. i The example linear equation is a waveform. The example linear equation is calculated by the clock compensation module 206 based on (i) Error1 when a reference clock time update Clock_Ref1 is received at Clock_Local1; (ii) Error2 when a reference clock time update Clock_Ref2 is received at Clock_Local2; and (iii) the duration between Clock_Local1 and Clock_Local2. In this example, both errors Error1 and Error2 are positive, and Error1 increases. It should be understood that in some scenarios, Error... i The value can be negative.
[0083] Figure 7 This is a flowchart illustrating a local clock update process 700 that can be performed by the clock compensation module 206.
[0084] At step S702, the clock compensation module 206 obtains the time (Clock_Local) of the local clock 204. As described above, the clock compensation module 206 is configured to receive local clock time updates from the local clock 204.
[0085] At step S704, the clock compensation module 206 uses the local clock time (Clock_Local) and the previously established approximation function to determine the error between the local clock 204 and the reference clock 108. Figure 8 The illustration shows how to use Clock_Local and a previously determined approximation function (in this example, a linear equation) to obtain data point 802 corresponding to the error at the time (Clock_Local) of local clock 204.
[0086] At step S706, the clock compensation module 206 uses (i) the local clock time Clock_Local and (ii) the error between the local clock and the reference clock to calculate the compensation time (t). comp Specifically, the compensation time can be calculated as follows:
[0087] t comp = Clock_Local – Error
[0088] In particular, the compensation time at any given time can be calculated by subtracting the approximation error at that point in time from the local time and the approximation error using the most recently generated equation.
[0089] In step S706, the clock compensation module 206 transmits at least one clock configuration message to the local clock 204 based on the compensation time in order to configure the local clock 204.
[0090] The clock compensation module 206 can transmit only a single clock configuration message to the local clock 204. The single clock configuration message may include the compensation time t. compAlternatively, a single clock configuration message may include instructions to the local clock 204 to speed up or slow down time values corresponding to errors (e.g., in seconds) to correct for the errors. The local clock 204 can be used to provide an accurate timestamp associated with anomalies observed in the waveform of the voltage or current being measured. In these implementations, these events may be sent up to a headend system (e.g., server 104) that collects such events from a large number of devices. It is desirable that the timestamps of these events be as accurate as possible to correlate whether events sent by two devices that are close to each other in time are related to the same event. For these implementations, the clock compensation module 206 preferably immediately adjusts the local clock 204 to the optimal approximate time (via the transmission of the single clock configuration message) such that the local clock 204 is closely synchronized with the reference clock 108. In other embodiments, the single clock configuration message may include a rate at which the local clock 204 should adjust the time held by the local clock 204. For example, the rate may be in seconds / second, seconds / hour, or milliseconds / hour, whereby the local clock 206 will adjust the amount in the numerator for each interval of the denominator measured by the local clock 204. Clock compensation module 206 can transmit multiple clock configuration messages to local clock 204. Local clock 204 can be used to measure the configured interval length, integrate the measurement over that interval length, calculate the value associated with the integrated data, and record them along with the interval's end timestamp (e.g., for demand and load curves). The minute top of local clock 204 is used to end these intervals. When time changes occur within an interval, the interval's duration will be longer or shorter than it actually is. If the change is large enough, the interval value needs to be discarded or marked as short or long. In these embodiments, it is preferable to extend the adjustment over several time intervals such that each interval is close enough to the correct duration that no data needs to be discarded or marked. Therefore, clock compensation module 206 can transmit multiple clock configuration messages to local clock 204, each clock configuration message including an instruction to speed up or slow down local clock 204 by a time value, wherein the sum of the time values of each clock configuration message is the error between local clock 204 and reference clock 108.
[0091] The clock compensation module 206 can operate in either of these ways (i.e., send one or more clock configuration messages to the local clock 204) and select the appropriate operating method based on the specific metering function implemented by the power consumption metering terminal 106.
[0092] At least one clock configuration message configures the local clock 204 to correct for the error between the local clock 204 and the reference clock 108. That is, the local clock 204 outputs a compensated time update based on at least one clock configuration message. In this document, we refer to the time update output by the local clock 204 based on at least one clock configuration message as the compensated time update (the time update output by the local clock 204 after clock correction is applied).
[0093] The local clock update process 700 can be executed at any point in time (not synchronized with the reference clock time update received from the reference clock 108).
[0094] The local clock update process 700 can be executed periodically by the clock compensation module 206. The frequency of executing the local clock update process 700 can be determined by the amount of drift between the local clock 204 and the reference clock 108, and the approximate achievable accuracy using the error. For example, if the reference clock time update is sent once per hour, the compensation algorithm can perform an adjustment every 5 minutes. In the first few days, the error seen when performing the reference clock update may still be close to the uncompensated time, but as the error estimation algorithm improves with more data points, improved performance is expected. Conversely, the reference clock update rate can be slowed down to once per day, while achieving the same error initially seen with an hourly update.
[0095] Periodic updates of the local clock, adjusted based on the calculated error, can drive the error between the reference clock 108 and the local clock 204 to zero. This minimizes clock drift in the power consumption metering terminal between reference clock updates and reduces the frequency at which reference clock updates need to occur. This advantageously reduces network traffic on the mesh network 102.
[0096] Additionally or alternatively, the initiation of the local clock update process 700, performed by the clock compensation module 206, may be triggered by an event. For example, the local clock update process 700 may be triggered when the approximation error exceeds a threshold. Since clock drift is typically affected by temperature, this may result in more updates during hot days and fewer updates at night.
[0097] As can be understood from the above, embodiments of this disclosure allow for a more accurate local clock to be maintained in the power consumption metering terminal over time relative to a reference clock. This enables a reduction in the number of devices in the mesh network 102 that require a reference clock 108, as devices can rely on other devices (with reference clock 108) to maintain accurate time. This further avoids erroneous time-related power consumption data being recorded and reported by the power consumption metering terminal.
[0098] Generally, any functionality described herein can be implemented using software, firmware, hardware (e.g., fixed logic circuitry), or a combination of these implementations. As used herein, the terms “module,” “function,” “component,” and “application” generally refer to software, firmware, hardware, or a combination thereof. In the case of a software implementation, a module, function, or logic represents program code that performs a specified task when executed on a processor (e.g., a CPU or multiple CPUs). The program code may be stored in one or more computer-readable storage devices. The techniques described are characterized by platform independence, meaning that these techniques can be implemented on a variety of commercial computing platforms with a wide range of processors.
[0099] Although this disclosure has been described with reference to specific embodiments as described above, it should be understood that these embodiments are merely illustrative and the claims are not limited to those embodiments. Modifications and substitutions will be able to be made by those skilled in the art in light of this disclosure, and such modifications and substitutions are considered to fall within the scope of the appended claims. Each feature disclosed or shown in this specification may be combined in any embodiment, either alone or in any suitable combination with any other feature disclosed or shown herein.
Claims
1. A power consumption metering terminal comprising: a local clock; a clock compensation module configured to: receive a plurality of reference clock time updates output by a reference clock external to the power consumption metering terminal; record a time of the local clock at which each of the plurality of reference clock time updates was received; and determine an approximation function of a development over time of an error between the local clock and the reference clock using the plurality of reference clock time updates and the times of the local clock; wherein the clock compensation module is further configured to perform a local clock update procedure, wherein the clock compensation module is further configured to: obtain a time of the local clock; determine an error between the local clock and the reference clock using the time of the local clock and the approximation function; calculate a compensation time using (i) the time of the local clock and (ii) the error between the local clock and the reference clock; and transmit at least one clock configuration message based on the compensation time to the local clock; wherein the local clock is configured to output a time update based on the at least one clock configuration message.
2. The power consumption metering terminal according to claim 1, wherein The at least one clock configuration message comprises only a single clock configuration message, the single clock configuration message comprising the compensation time.
3. The power consumption metering terminal according to claim 1, wherein The at least one clock configuration message comprises only a single clock configuration message, the single clock configuration message comprising an instruction to cause the local clock to accelerate or decelerate by a time value corresponding to the error between the local clock and the reference clock.
4. The power consumption metering terminal according to claim 1, wherein The at least one clock configuration message comprises a plurality of clock configuration messages, the clock compensation module being configured to successively send the plurality of clock configuration messages, each of the plurality of clock configuration messages comprising an instruction to cause the local clock to accelerate or decelerate by a time value, wherein a sum of the time values of each of the plurality of clock configuration messages is equal to the error between the local clock and the reference clock.
5. A power consumption metering terminal according to any preceding claim, wherein, The clock compensation module is configured to receive one or more further reference clock time updates output by the reference clock and to adjust the approximation function using the plurality of reference clock time updates and the one or more further reference clock time updates.
6. A power consumption metering terminal according to any preceding claim, wherein, The power consumption metering terminal comprises: a communication unit configured to receive the plurality of reference clock time updates; and a metering unit, wherein the metering unit comprises a metering application configured to associate (i) power related data associated with power consumed in an electricity distribution system with (ii) the time updates to generate time based power related data; wherein the communication unit is further configured to communicate the time based power related data to one or more external devices.
7. The power consumption metering terminal according to claim 6, wherein The metering unit comprises the local clock and the clock compensation module.
8. The power consumption metering terminal according to claim 6, wherein The communication unit comprises the local clock and the clock compensation module.
9. The power consumption metering terminal according to any one of claims 6 to 8, wherein, The metering unit comprises: an interface to the electricity distribution system, the analog power related data being associated with power consumed in the electricity distribution system; analog-to-digital conversion circuitry to convert the analog power-related data into digital power-related data; and a processor configured to process the digital power-related data to generate the power-related data and to provide the power-related data to the metering application.
10. The power consumption metering terminal according to any one of claims 6 to 9, wherein, the communication unit is configured to communicate the time-based power-related data to the one or more external devices via a mesh-based communication network.
11. The electricity consumption metering terminal of any preceding claim, wherein, the clock compensation module is configured to periodically receive the reference clock time updates.
12. The electricity consumption metering terminal of any preceding claim, wherein, the clock compensation module is configured to periodically perform the local clock update procedure.
13. A mesh-based communication network comprising: a power consumption metering terminal according to any preceding claim; and at least one network device, wherein a network device of the at least one network device comprises the reference clock.
14. The mesh-based communication network of claim 13, wherein, the network device comprising the reference clock is another power consumption metering terminal.
15. The mesh-based communication network of claim 13, wherein, the network device comprising the reference clock is a server.
16. A method of updating a local clock on a power consumption metering terminal, the method performed by a clock compensation module on the power consumption metering terminal and comprising: receiving a plurality of reference clock time updates output by a reference clock external to the power consumption metering terminal; recording a time of the local clock at which each reference clock time update of the plurality of reference clock time updates is received; and determining, using the plurality of reference clock time updates and the times of the local clock, an approximation function of a development over time of an error between the local clock and the reference clock; and performing a local clock update procedure by: obtaining a time of the local clock; determining, using the time of the local clock and the approximation function, an error between the local clock and the reference clock; calculating, using (i) the time of the local clock and (ii) the error between the local clock and the reference clock, a compensation time; and transmitting at least one clock configuration message based on the compensation time to the local clock.
17. A non-transitory computer-readable storage medium comprising at least one instruction which, when executed by at least one processor, causes the at least one processor to perform the method of claim 16.