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

Since firmware 5 Athom thought it wise to change the time that apps see to UTC. So that is probably why.

Mmh yes… I will check it out. Again a problem that is making the app logic complicated.

Thx for staying up this late and reporting :yawning_face:

Thank you.
Just discovered another thing. Could be relevant. I have set up loging from your app, using the Simple Log app. And funny thing. When I export the log, the time-stamps seem to adjust an hour back.
So I tried to log kwh prev. day at 00:00. And when i export the log the timestamp changes to 23:00.

I just uploaded a new version 3.1.0 of the app.

  • Fixed time zone offset.
  • Updated driver/device/capability icons.
2 Likes

I know that this app does not support devices without a meter_power capability, and unfortunately quite a few devices can measure power, but lacks the accumulation feature.

Are there any apps that can create a virtual device that can take power measurements from such a device and accumulate to a meter_power property which can be used by PBTH?

It would not be as good as a device which logs and stores this internally, but it might still be good enough for some purposes. It would basically have to trigger at every received power measurement, and create a timestamp. When the next measurement is received, it could calculate and aggregate the energy by looking at the time difference between the measurements and the value. I know something like this is available for Home Assistant:

This uses the Riemann sum, which gives a better approximation than the simplest approach outlined above.

@Gruijter I understand that you are not interested in adding such functionality into PBTH natively, right?

Adding a virtual device that uses measure_power (watts, not kWh) would theoretically be possible. But it would always be ‘handicapped’ since the kWh would be estimated from the actual power usage. Over time this will always lead to a significant offset of the kWh meter.

It definitely does not have any priority with me because it would extend the scope of my app. Maybe next year if I have spare time left. But in the mean time anyone is welcome to add a driver via a Github pull request.

I agree it would be less accurate, but it would still be useful, I think.

I have just started with Homey, and I don’t really know Javascript or Node.js, but I do work with programming, so if I am able to do this myself, I might try. I wonder if something like this could be achieved with homeyscript, at least as an experiment. Having a proper driver would of course be much better.

Unfortunately this week some errors, send a report:

b614d916-0cfe-4db5-a51e-b39859c125a7

the log states the origin device is missing. So try resetting that device. And did you already try rebooting Homey?

How does this app integrate with Tibber? Can’t see any options regarding Tibber.

Looking at the app code on github it should work with pulse.

Hi Robin,

I checked that, I almost every day have to restart the app, the source app is yours also :slight_smile:

And this situation occured since the major update of the source app.

Warm regards Wout

I use the same configuration myself but cannot replicate the issue. Do you have bad network connection with the LS120 or with Homey maybe?

works with Tibber

1 Like

Just released as stable version 3.2.0:

  • Fixed missing source watchdog.
  • Faster recovery after source device available again.
  • athom-api@3.7.1.

This should fix the unavailable devices after a Homey boot (But please do have patience, it can take up to an hour after Homey reboots)

2 Likes

First q; Is there a way to see when I have created the PBTH device?

Second; And the PBTH device bases it values on the device mirrored. I’m using ‘shelly’ devices for both my dryer as for my washing machine.

Apparently, and I 've never noticed this before, it resets it’s value.

image

I honestly wouldn’t know based on what it resets. Maybe FW update. Is there a way to tackle this? I wanted to check how much my dryer costs per year, but the year value was nearly the same as the month so I noticed it.

Look at when the insights start

If the Shelly device resets its meter_power, the dev of the Shelly app may have a solution for you. For now you could manually trace back from Insights how much the dishwasher used last year.

I have had the PBTH app from the start and noticed that the measurements halted somewhere around august-september, but haven’t noticed it before.

I added the PBTH devices again.

I also removed the app and installed it again.

I have made a PBTH device from my household electric inlet measurement. The PBTH device shows the readings correctly when I set the Update inverval into 0, but it loads the system quite heavily, because the shelly 3EM meter is eager to report it’s energy measurement quite often. When I change the Update interval into something else the PBTH device doesn’'t update anymore. (Tried 1min and 5min)

Does anyone have the same problem? Is the update interval working correctly or what could be the problem.

Homey Pro 7.2.1
PBTH 3.2.0

Insights does indeed give a date. Don’t know if it is representable though. for the device itself is, but for the PBTH device it isn’t. That gives a value if it starts consuming. Reason I’m asking is because it seems to reset it self when the Shelly device meter_power resets. I’ll post in the Shelly thread, thanks.


Indeed get’s reset as you suspected: Keep power meter values as they reset when power is lost to the shelly device · Issue #102 · jghaanstra/cloud.shelly · GitHub

1 Like

New test version 3.3.0 is available

  • Skip checking source device ready on restart.
  • Replace athom-api with homey-api@1.5.0

Replacing the recently deprecated athom-api with the new homey-api is a risky step. I hope Athom has ironed out all bugs. But then again, it might be a stability improvement for those users that had problems with PBTH devices not starting properly after a Homey boot.

When testing, please let us know how 3.3.0 is holding up for you: Power by the Hour | Homey

2 Likes