Ad Widget

Collapse

Utility power meter - pulse read and incrementation of kWh

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Molleby
    Junior Member
    • May 2022
    • 1

    #1

    Utility power meter - pulse read and incrementation of kWh

    Hi all, first time poster here

    We have an optical pulse meter attached to an utility meter, where 10.000 pulses designates an increase of 1 kWh. Using a zabbix agent2 on a Raspberry Pi, we send a 1 minute sum of pulses to Zabbix. There we convert the pulses to Watts and show that in a graph. Ok, so far so good.

    What we also need is the total value of the kWh of the utility meter. We perform a manual reading of the utility meter when we start the data stream, for example we measured total kWh to 82654 on May 10th, 2022, at 10:00:00. For every 10.000th pulse, we need to increase the total kWh by 1.

    I guess I could create a calculated item, that gets the sum off all 1 minutes pulse measurements from May 10th, 2022, at 10:00:00 and until the present, divide it by 10.000 and add the result to the 82654 kWh. However, I'm not sure that is a good idea... as time goes by and more data is stored, the summation is going to become heavier and heavier.

    What I would like to do instead is have some kind of separate special item that stores an internal pulse counter, ranging from 0 to 10.000. It uses the 1 min. pulse sum items from the agent and increments its own value. When it hits 10.000, it restarts its count, and the total kWh value is incremented by 1.

    Is any of this possible in Zabbix? For example, could I save the manual kWh read value and the 10.000 cycle counter in macros and update those macros via script?
Working...