Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Energy consumption hour by hour #11

Open
SteffenSauerbrunn opened this issue May 3, 2020 · 3 comments
Open

Energy consumption hour by hour #11

SteffenSauerbrunn opened this issue May 3, 2020 · 3 comments
Labels
enhancement New feature or request in-roadmap

Comments

@SteffenSauerbrunn
Copy link

Hello,

great app.

When will the app provide energy consumption hour by hour? It's on the roadmap, just keen to get an idea whether this is added anytime soon.

Thanks

Steffen

@tnmendes
Copy link
Owner

tnmendes commented May 3, 2020

Thank you Steffen :)

TP-Link devices natively do not have the ability to see consumption hourly, I can only see consumption for the day. This means that I will need a server to query hourly what is the consumption and make a chart over that information.

This has not yet been developed because I will need to develop a server project that asks the TP-Link server what is the consumption of each device every hour.

I've been wondering how to do this but I realized that maybe there will be a problem. Let's imagine that I have 5000 unique users of the app and that each user on average has 8 devices.
So in an hour I will do 40000 (5000 * 8) requests to TP-LInk servers.
And in one day 40000 * 24 = 960000 requests.

These numbers are a little scary I can't make so many requests so I will have to think of a solution :-|

So in relation to your question of when it will be ready never before the next 4 months and will have some kind of limitation.
But before that, I want to see if I can improve the experience using smart bulbs that is my next goal.

@tnmendes tnmendes added the enhancement New feature or request label May 3, 2020
@tnmendes
Copy link
Owner

Hey @atGordo, Watt is not able to poll directly from the devices (Kasa Smart app does that). Watt is polling from TP-Link servers.
If you have some mini server or raspberry pie there is some free project on Github that does that but you have to have the mini server running 24 hours (raspberry pie for a month has like the electric cost of +/- 8kWh)

@wjcroft
Copy link

wjcroft commented Nov 23, 2021

@SteffenSauerbrunn here are some related resources,

https://community.tp-link.com/en/home/forum/topic/169586

Mike's server can either run on an Android, or just the Java version on Mac, Windows or Linux / Pi. In the solution mentioned above his Android server program uses an extension that dumps the data into a Google Drive file. The links below document his general framework.

https://sites.google.com/site/mppsuite/
https://sites.google.com/site/mppsuite/downloads/wemoserver-java?authuser=0

His Android server,

https://play.google.com/store/apps/details?id=mpp.android.wemo&hl=en_US&gl=US
https://play.google.com/store/apps/developer?id=MikeP&hl=en_US&gl=US [MikeP, the developer]

His Java server creates a text log file with new data samples every 3 minutes. The simplest approach might be to just read and parse his log file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request in-roadmap
Projects
None yet
Development

No branches or pull requests

4 participants
@wjcroft @tnmendes @SteffenSauerbrunn and others