peuter / ecoflow

Provides access to ecoflow devices via the homie MQTT convention
3 stars 2 forks source link

Stuck in "last heartbeat outdated, requesting new one" #9

Open og-gh opened 1 week ago

og-gh commented 1 week ago

Hi @peuter ,

thanks for your great work. I'm facing some issue on a daily basis. At some point I get the message model.ecoflow.base_device - Thread-1 - INFO - last heartbeat outdated, requesting new one This message is continously coming until I log in with my ECOFLOW app. Do you have any idea what could cause this? I have a POWERSTREAM defined.

Thanks in advance! og-gh

peuter commented 1 week ago

Ecoflow disconnects third-party clients after a certain amount of time. The message you see is shown when the client detects that and tries to re-connect. That was the workaround I builtin to get rid of that problem. I have that log message also every couple of minutes but that data is still coming in and everything is working.

If you have troubles getting data, Ecoflow might have done some extra tricks to make the live harder for non-official clients like this one. If that is the case I have no solution for that. Ecoflow wants third-party client to use the official API, but back in the days when I wrote this client the official API was very limited and did not provide the features I needed and did not support the devices I use. Might have changed in the meantime, but I do not have the time to check an re-write this client to use the official API.

og-gh commented 1 week ago

Hi @peuter , many thanks for your fast response! Yes, it seems like they implemented some timeout on 3rd party connection. I will check if I can adapt something to get it more reliable. If so, I will share.

Thanks a lot! og-gh