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

Have a look at this thread: ANWB Dynamische Energietarieven (adv) Flow maken - #5 by Gruijter

1 Like

I use the Smart Gateway App with the P1 wifi gateway.

Might now know what the problem is (might be). I bet the PBTH app uses the (sum of) all L1 counters as source (huidig verbruik). This becomes zero when ‘huidige opbrengst’ becomes positive. I requested the developer (@MarcelT ) to add an extra icon to the App to show the sum of all generated and used power in one icon: netto vermogen.

Here the screens with the icons from the Gateway App:

Netto vermogen (recently added by the developer) is the sum of all consumption and deliveries :

The power usage and consumption were seen as two seperate values. One was always zero… I bet PBTH uses ‘huidig verbruik’ value as source, thus never sees negative values.

PBTH can use Watt as source (measure_power) if you have that enabled in the PBTH advanced settings.

But looking at your screenshots I think using ‘energie totaal’ (kWh) would be the best choice. I assume that the kWh goes down when you deliver to the grid. Can you confirm that?

If ‘energie totaal’ is indeed doing that, It is not named meter_power in Homey. If I know what it is named in the Smart Gateway app I might be able to add it for exception handling in PBTH. @MarcelT I cannot find your source code online. Can you help out here?

1 Like

v5.4.6 was just released as test: Power by the Hour | Homey

  • Summarizer: Added kWh source support for Huawei solar and Iungo
  • Fix currency unit change.
  • homey-api@1.10.20

@Ludwig_Hallgren this version adds kWh support for your Huawei Solar device.
@MarcoRuiter this adds kWh support for Iungo.
If you add a new summarizer it will use kWh as source, in stead of Watts. You can also force to have your existing PBTH summarizer use kWh by disabling ‘use watt as source’ in the advanced settings. Be aware that the PBTH kWh counter will do a one-time jump, and you need to manually compensate the day/month/year start values.

2 Likes

No, it does not go down. ‘Productie dal’ does increase due to delivery right now:

Would be great if @MarcelT and you could sync these great Apps!

PS
Smart Gateways App is here

I know. But I need source code :wink:

1 Like

v4.5.7 is released:

  • Summarizer: Fix manual money settings

After consulting the developer of the Smart Gateway App I was advised to remove the original added P1 gateway devise and re-add it.

I don’t mind loosing the insights history, but would live to keep the history / stats of the PBTH devices (gas and electricity) linked to this devise.

What is the best way to approach this? Is it possible to remove a source and add it again *and8 keeping the PBTH devise?

Thanks!

If you delete the device you will lose history. Nothing can be changed about that.

You could archive all Insights before deleting the device: [APP][Pro] Archive Insights - export all your Insights data to a NAS, FTP or web folder

Also I would advice to make a Homey backup first, so that you can revert to the situation before deleting the device.

If you dont delete the existing PBTH device, and just create a new (second) PBTH device, you will keep the existing PBTH history. But since the source device will be missing, the PBTH device will say it is unavailable. Insights should be there though. (I think ,but cannot guarantee anything :joy:)

1 Like

Thank you @Gruijter!

1 Like

@Ria_Banis
can you post a screenshot of the PBTH device settings (top part),
and insights graphs of past 24 hrs for:

  • PBTH ‘this_hour’
  • the source device (solarEdge) energy (kWh)

Also on Github you mentioned a second device not working as it should. Can you post screenshots showing what the problem is?

Start of new month, error on values?

The first of March, so new month. The value for “start of day” and “start of month” are not the same. Why is that.

Also, I see that the actual gas consumption today is 11 m3, but the same measurement in Domoticz, shows 5,x m3. This might be related?

What start date did you set? I bet you don’t start the month on the first day of the month.

I think I do!

PS
The meter total counter (huidige waarde) in Domoticz and PBTH are equal!

@Eternity Wow. Your ‘this month start’ seems off. I don’t have the issue you have and I cannot reproduce that.

Is your Homey on the right date/time and time zone?
Did your Homey maybe restart at midnight?

If you restart PBTH or restart Homey now, does anything change?

Homey had a firmware update yesterday or the day before yesterday, so it did reboot.

Date seems correct:

I will first restart PBTH and check the stats. If that is not the solution, I will PTP.

Will let you know the outcome!

Restarting the App didn’t do the trick.
And, a PTP didn’t either.

I have sent a diagnostic report and here is the code: 03099dc1-03c8-4246-a68f-18091ae7914f

As said, the actual gas usage today seems incorrect too. Perhaps that is related?

PS
As the counter seen in both Domoticz and PBTH show the same value, I am not worried about the year stats.

Ok thx. Need to dig in my code then. Diagnostics report shows nothing weird. I cannot reproduce the issue myself :thinking: so makes it hard to find the problem.

1 Like

For me only March did not start at zero gas consumption. The March gas consumption is the sum of February and March. The year total is correct!

Perhaps that helps debug!

UPDATE
I edited the GAS start of March 1st and that was the solution for me. Now let’s hope April 1st will be ‘normal’ again.

1 Like

I have made a mistake, @Gruijter! Everything is fine with me.
The problem why I thought that PBTH gave a wrong value was that the device, a Shelly Plus Plug S (it measures the power and energy of a small PV system), recorded incorrectly. Besides PBTH I have a control flow that calculates the daily energy, but at a different time (between 00:00 o’clock and 60 minutes after sunset). And this value was different from the one in the PBTH device.

Sorry for the trouble!

1 Like