tijsverkoyen / HomeAssistant-FusionSolar

Integrate FusionSolar into your Home Assistant.
MIT License
133 stars 25 forks source link

Possible conflict between integration API calls and huawei portal #117

Closed jfbuggen closed 6 months ago

jfbuggen commented 7 months ago

Hello,

I noticed a strange behavior which I would like to share.

Not sure this can be qualified as an issue at the integration side, though, as I think it is more at Huawei side. But could be worth a small change request (see below).

-> I logged-in on Huawei's Fusionsolar portal and went to the battery configuration parameters to force a battery charging. -> The charging didn't start. I tried multiple times at different moments of the day. Same result: the requset to force charging is ignored despite the portal indicating that the parameters were successfully set. Sometimes after an automatic refresh, the interface is back to "stop" instead of "charge". -> I thought that maybe there is a conflict between the API calls of the HA integration and the portal (i.e. the portal does not like at the same time a user logged in via the API and via the portal itself, even if the integration just gets values and does not set anything). -> I disabled the integration in HA and then requested a new "force charge" via the Huawei portal. And it worked! -> After a few minutes I re-enabled the integration in HA and the battery continued to charge.

I was wondering if somebody noticed a smiliar behavior. Maybe it is specific to that function to force battery charging (at least triggering a firmware update via the portal seems not to be impacted by the API calls).

If other users encounter the problem, I was wondering if a switch could be implemented in the integration, to temporarily suspend any API call. That would enable triggering commands on the Huawei portal without the need to fully disable the integration (which requires to restart HA).

I would be happy to get your views on this.

Thanks!

J-F

tijsverkoyen commented 7 months ago

I don't own a battery, so I can't verify this behaviour. Maybe you can contact Huawei Support to verify this.

What could be done is that after the calls are done the integration also logs out.