# \[APP\]\[Pro\] Power by the Hour: Insights per hour, day, month and year

**URL:** <https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535>\
**Category:** Apps\
**Tags:** app, tools\
**Created:** [November 10, 2019, 10:06pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535 "2019-11-10T22:06:03Z")\
**Posts on this page:** 20\
**Page:** 30

<div class="post-metadata">

**Author:** ![Jeroen\_Tebbens](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jeroen_tebbens/32/62246_2.png) [@Jeroen\_Tebbens](https://community.homey.app/u/Jeroen_Tebbens)\
**Post date:** [April 3, 2022, 4:53am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/589 "2022-04-03T04:53:31Z")

</div>

Hi,

I try to understand the problem as we seem to compare all output from P1, Energylink and a calculated/derived result from PBTH.

But first, how did you connect both these devices? Is there an active splitter on de P1 port?  
How are Energylink and P1 dongle powered?

Further I need output from:

Energylink: [http://honewizard-ip/homewizardpassword/el/get/0/readings](http://honewizard-ip/homewizardpassword/el/get/0/readings)  
P1: [http://p1-dongle-ip/api/v1/data](http://p1-dongle-ip/api/v1/data)

Cheers,  
Jeroen

---

<div class="post-metadata">

**Author:** ![Mike1233](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mike1233/32/20991_2.png) [@Mike1233](https://community.homey.app/u/Mike1233)\
**Post date:** [April 3, 2022, 9:22am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/590 "2022-04-03T09:22:57Z")

</div>

@Jeroen_Tebbens  
I use both devices because if my HW stops working I the go further wit the P1.  
I want to know if it works like I want. There are sometimes different outcomes of the used power of the day in the HW original apps from about 500Wh and sometimes 1kWh a day.  
That is a small issue but strange. It has nothing to do with you’re app. Just tell you why I use both.

Both the devices are connected to a active P1 splitter.  
The Energylink and the P1 have there own adapter. Because my meter is a type SMR 4.  
It has happend now 2 times that the “Start of the month” changed to the wrong value. I own the P1 just about two month. With the Energylink I have no problems. And I mean that it has happened by the app PBTH.

The links you have put here do nothing, sorry.  
What should I try?  
But if you think that is everything is good I can wait a couple of days till the first of May and look what value I then get.  
Thank you both. @Gruijter

---

<div class="post-metadata">

**Author:** ![Jeroen\_Tebbens](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jeroen_tebbens/32/62246_2.png) [@Jeroen\_Tebbens](https://community.homey.app/u/Jeroen_Tebbens)\
**Post date:** [April 3, 2022, 10:00am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/591 "2022-04-03T10:00:04Z")

</div>

Sorry I need the output of the devices (values).  
You have to modify the links I shared to reflect the ip addresses as I don’t know your network.

Further Energylink can act weird sometimes. I occasionally get 1000w for 3 hours duration at night which is wrong. I don’t trust my Energylink anymore but have it to support my Homewizard app.

---

<div class="post-metadata">

**Author:** ![Mike1233](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mike1233/32/20991_2.png) [@Mike1233](https://community.homey.app/u/Mike1233)\
**Post date:** [April 3, 2022, 10:58am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/592 "2022-04-03T10:58:33Z")

</div>

Ah, OK, sorry. Now I see it.  
When I see the difference with the Energylink and the elecricity company then it is at the and of the Mont almost the same for both. So I think that is no problem.

Homewizard Energylink:  
{“status”: “ok”, “version”: “3.403”, “request”: {“route”: “/el” }, “response”: [{“type”:“electricity”,“tariff”:1,“consumed”:12037.748,“produced”:783.346},{“type”:“electricity”,“tariff”:2,“consumed”:10903.946,“produced”:1841.028},{“type”:“gas”,“consumed”:3267.636,“timestamp”:1649008800}]}

P1:  
{“smr\_version”:42,“meter\_model”:“Kaifa KAIFA-METER”,“wifi\_ssid”:“ASUS2”,“wifi\_strength”:100,“total\_power\_import\_t1\_kwh”:12037.747,“total\_power\_import\_t2\_kwh”:10903.945,“total\_power\_export\_t1\_kwh”:783.405,“total\_power\_export\_t2\_kwh”:1841.028,“active\_power\_w”:-51,“active\_power\_l1\_w”:-258,“active\_power\_l2\_w”:null,“active\_power\_l3\_w”:null,“total\_gas\_m3”:3267.636,“gas\_timestamp”:220403120000}

---

<div class="post-metadata">

**Author:** ![Jeroen\_Tebbens](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jeroen_tebbens/32/62246_2.png) [@Jeroen\_Tebbens](https://community.homey.app/u/Jeroen_Tebbens)\
**Post date:** [April 6, 2022, 12:50pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/593 "2022-04-06T12:50:32Z")

</div>

@Mike1233 & @Gruijter

meter\_power is the aggregated value sum (consumption T1/T2) - sum (production solar T1/T2).  
So can’t see the problem there. Also both Energylink and P1 get roughly same numbers.

```
    "meter_power": {
      "title": {
        "en": "Total usage KWh",
        "nl": "Totaal verbruik KWh"
      }

```

this.setCapabilityValue(‘meter\_power’, ((data.total\_power\_import\_t1\_kwh+data.total\_power\_import\_t2\_kwh)-(data.total\_power\_export\_t1\_kwh+data.total\_power\_export\_t2\_kwh))).catch(this.error);

---

<div class="post-metadata">

**Author:** ![ECKEROTH](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/eckeroth/32/48469_2.png) [@ECKEROTH](https://community.homey.app/u/ECKEROTH)\
**Post date:** [April 7, 2022, 7:54am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/594 "2022-04-07T07:54:36Z")

</div>

Hi

I am a happy user of this app in the electricity side and would now also like to measure my water consumption. What is the best unit and solution for this purpose?

My water meter looks like this:

 ![vandmaler](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/2/e2ea5b01e883442f153fbff1fc8cdf11d65558a6.jpeg)

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 7, 2022, 8:04am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/595 "2022-04-07T08:04:04Z")

</div>

Do I see an LED pulse on there? If so you can probably use the Youless LS120.

---

<div class="post-metadata">

**Author:** ![ECKEROTH](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/eckeroth/32/48469_2.png) [@ECKEROTH](https://community.homey.app/u/ECKEROTH)\
**Post date:** [April 7, 2022, 9:51am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/596 "2022-04-07T09:51:58Z")

</div>

I do not see any LED pulse when I have water consumption!  
Can this pulse be seen with the naked eye? Can it be turned on/off somehow?

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 7, 2022, 11:44am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/597 "2022-04-07T11:44:56Z")

</div>

Wrong place to ask. Ask your supplier what interfaces the meter can supply to the outside world.

All I know is that the Youless can work with a pulse, either LED or dry contact… Also the youless has a Homey app that supports a water meter that can be used by PBTH.

---

<div class="post-metadata">

**Author:** ![Ronald\_de\_Boer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronald_de_boer/32/13873_2.png) [@Ronald\_de\_Boer](https://community.homey.app/u/Ronald_de_Boer)\
**Post date:** [April 11, 2022, 7:13pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/598 "2022-04-11T19:13:55Z")

</div>

Hi @Gruijter, first of all; what a great app you’ve built. It works really nice and stable and gives a very good insight in my energy usage right now.

There is one thing I cannot fix and maybe you can help me.  
First of all let me mention that I use a P1 Plugwise Smile to read my Energy meters.  
To calculate the amount of KWH I deliver back to the net I use the app Flow Utilities.  
With this app I total the production in high and low tariff. The difference during the day is send to a virtual meter from Power by the Hour.  
During the day this gives me insight in the current production of the day.

The thing I cannot fix has to do with the “This day start”  
When I use the function “has a daily reset” the start of the day gives a amount which I cannot reproduce and is not 0.  
When I do not use the function “has a daily reset” the value of the “start of the day” is the value of the previous day.

These flows are created to make it work:  
[https://homey.app/nl-nl/flow/Rc02q0/](https://homey.app/nl-nl/flow/Rc02q0/)  
[https://homey.app/nl-nl/flow/j4B2q0/](https://homey.app/nl-nl/flow/j4B2q0/)  
The values that are calculated match the values which my energy supplier calculates.

Anyone a idea how to solve this without having to set the “start of the day” manually to 0 each day?

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 11, 2022, 7:29pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/599 "2022-04-11T19:29:48Z")

</div>

> [@Ronald\_de\_Boer](#):
>
> what a great app you’ve built.

🥰

> [@Ronald\_de\_Boer](#):
>
> without having to set the “start of the day” manually to 0

Im not sure what your flows are doing, and also not sure what you want to achieve with PBTH. What exactly is the second flow sending to PBTH? Is that the total kWh returned to the grid ever, or only the kWh returned for a single day?

If it is only for a single day, it will start again at 0 the next day right? In that case you need to set ‘has daily reset’ in PBTH. The value ‘start of the day’ in that case is only an internal value used by PBTH, and there is no need to change it manually. Why do you want to change it?

---

<div class="post-metadata">

**Author:** ![Ronald\_de\_Boer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronald_de_boer/32/13873_2.png) [@Ronald\_de\_Boer](https://community.homey.app/u/Ronald_de_Boer)\
**Post date:** [April 11, 2022, 8:07pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/600 "2022-04-11T20:07:07Z")

</div>

> [@Gruijter](#):
>
> Im not sure what your flows are doing, and also not sure what you want to achieve with PBTH. What exactly is the second flow sending to PBTH? Is that the total kWh returned to the grid ever, or only the kWh returned for a single day?

I want to see how much kWh I return in a single day. This should be the value “kWh deze dag” of the virtual meter

> [@Gruijter](#):
>
> If it is only for a single day, it will start again at 0 the next day right? In that case you need to set ‘has daily reset’ in PBTH. The value ‘start of the day’ in that case is only an internal value used by PBTH, and there is no need to change it manually. Why do you want to change it?

When I won’t change the value, the actual value at “kWh deze dag” is not correct.

For now I changed the setting to “ has a daily reset”  
And will have a look at it tomorrow.

---

<div class="post-metadata">

**Author:** ![Mike1233](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mike1233/32/20991_2.png) [@Mike1233](https://community.homey.app/u/Mike1233)\
**Post date:** [April 11, 2022, 8:21pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/601 "2022-04-11T20:21:05Z")

</div>

I calculate the usage of a day with Flow Utilities with this flows.  
[https://homey.app/f/4Gjhq0](https://homey.app/f/4Gjhq0)

[https://homey.app/f/\_HNhq0](https://homey.app/f/_HNhq0)

And for the P1 you should use the value “TOTAAL verbruik kWh”.

If this is what you want.

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 11, 2022, 8:59pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/602 "2022-04-11T20:59:14Z")

</div>

I think @Ronald_de_Boer only wants to keep track of the returned power, not the total power. I just created a flow myself to do this. Im using a single flow, and use the standard logic cards to add the day/night values together. Since this gives the total returned kWh that does not reset to 0, I do not enable the ‘has daily reset’.

Will know in a day or 2 if this works, but I dont know why it wouldnt work.

[https://homey.app/f/pgJpq0](https://homey.app/f/pgJpq0)

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 12, 2022, 8:53am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/603 "2022-04-12T08:53:22Z")

</div>

@spndk spotprices for DK1 and DK2 are already available in the Power By The Hour app.

---

<div class="post-metadata">

**Author:** ![Ronald\_de\_Boer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronald_de_boer/32/13873_2.png) [@Ronald\_de\_Boer](https://community.homey.app/u/Ronald_de_Boer)\
**Post date:** [April 12, 2022, 12:49pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/604 "2022-04-12T12:49:41Z")

</div>

Yes, you are right.  
I only want to track the returned power and I was thinking to difficult…  
Whith flow utilities I was already calculating the things PBTH also can do 🙂  
Your example flow does indeed do the trick.  
Thanks for your help!

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [April 19, 2022, 7:02pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/605 "2022-04-19T19:02:54Z")

</div>

version 4.2.4 is ready for testing

- homey-api@1.5.26.

---

<div class="post-metadata">

**Author:** ![Ronald\_de\_Boer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/ronald_de_boer/32/13873_2.png) [@Ronald\_de\_Boer](https://community.homey.app/u/Ronald_de_Boer)\
**Post date:** [April 21, 2022, 2:02pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/606 "2022-04-21T14:02:27Z")

</div>

Hi @Gruijter ,

Saw you updated the PBTH app and since then the calculation of my virtual “Teruglevering” does not work anymore.  
It does something strange calculation with the current value.  
The actual value I send with your example flow should be 3411.327  
Can you look into it?

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/e/fe3a45582ff9c05e46adb2e5c190988be3204633.png)

---

<div class="post-metadata">

**Author:** ![Mike1233](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mike1233/32/20991_2.png) [@Mike1233](https://community.homey.app/u/Mike1233)\
**Post date:** [May 1, 2022, 11:20am UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/607 "2022-05-01T11:20:29Z")

</div>

I have a strange thing with the value of the P1 meter with tis month starts. It is 2  
120 kWh off.  
I also use the Energylink and that one has no problem.

 ![Screenshot_20220501-125047_Homey](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/7/a7bb66be8c391400abde59da94ad054d5e3c72d6.jpeg)

 ![Screenshot_20220501-125119_Homey](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/5/9/59fa5457ff5c81e2a453d3ac787c6d2965e75740.jpeg)

 ![Screenshot_20220501-125208_Homey](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/0/8/084f0dd82528f326419bb92f7a165b3145d7f7ed.jpeg)

 ![Screenshot_20220501-130859_Homey](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/e/1efcaf1155f635804e271b83749354f357702f99.jpeg)

Restart the app does not change anything.  
I am still on Homey 7.2.0

---

<div class="post-metadata">

**Author:** ![Gruijter](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/gruijter/32/1973_2.png) [@Gruijter](https://community.homey.app/u/Gruijter)\
**Post date:** [May 1, 2022, 12:19pm UTC](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535/608 "2022-05-01T12:19:39Z")

</div>

You are starting the month of both devices on a different day of the month…

[Previous page](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535.md?page=29)

[Next page](https://community.homey.app/t/app-pro-power-by-the-hour-insights-per-hour-day-month-and-year/20535.md?page=31)
