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

Suggestion: Process Sleep time #30

Open
Jabroni opened this issue May 12, 2022 · 2 comments
Open

Suggestion: Process Sleep time #30

Jabroni opened this issue May 12, 2022 · 2 comments

Comments

@Jabroni
Copy link

Jabroni commented May 12, 2022

Was wondering maybe it would be a good idea to have in the config a way to set up work times for the script/requests, so whenever its night time it doesnt hammer solarman webservers with hits when we know our inverters are offline.

That would reduce the number of daily requests by at least 30% (and reduce the chances that maybe someday they see this as hammering their API and remove us access to it)

@mpepping
Copy link
Owner

Definitely a good idea. The Solarman API also offers a method to renew tokens, instead of requesting a new token on every run. This should also be more friendly to the API. Your suggestion is interesting as well. Not sure how to implement that yet, but it's on the list :)

@mt-mrx
Copy link

mt-mrx commented Oct 15, 2022

I really like this suggestion, but instead of defining hard "work times", the sunrise and sunset times could be used. Calculate them every day and go to sleep for example 30 minutes after sunset and awake 30 minutes before sunrise.
I'm doing something like that on an ESP8266 which is battery operated and measures outdoor illuminance.
There should be libraries out there which can do the calculation in python and the only thing you need for that is accurate time, latitude and longitude and an offset variable you want to wake before sunrise and go to sleep after sunset.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants