krbaker / hass-sunpower

Home Assistant SunPower Integration using the local installer ethernet interface.
Apache License 2.0
63 stars 23 forks source link

Could refresh time be made into a config option? #45

Closed Spencer-Sawyer closed 1 year ago

Spencer-Sawyer commented 1 year ago

I was curious if the UPDATE_INTERVAL constant could be made into a config option so I could poll every minute or so; I was thinking about making my home more responsive to demand spikes. https://github.com/krbaker/hass-sunpower/blob/e1e2bf20c790197d078f20db43fac2bf7a335c8f/custom_components/sunpower/const.py#L33

krbaker commented 1 year ago

I've seen the get devices command take a very long timer to return. This was the lowest value that seemed to be reliable. Are you seeing otherwise? (if you want to test you can edit that line in yoru install of this.

Also note that things like the GEM (Green Eye Monitor) don't work so well when refreshed to often as it puts a lot of strain on the state DB from what I understand.

krbaker commented 1 year ago

I'm going to close this, I think this is currently the optimal value for reliability (future PVS models might change this)