ewelink-api icon indicating copy to clipboard operation
ewelink-api copied to clipboard

Error power usage data not found.

Open o-SAM-a-98 opened this issue 3 years ago • 5 comments

Hi, I have been using this API with my device, the Sonoff POW. All the other functions work supported by this device work, like for example toggling function and the status function. My issue is that when I request power usage data from the device I get nothing.
this is what i get { error: 'No power usage data found' } keeping in mind that i have the latest firmware installed.

Any assistance with this issue will be greatly appreciated. Regards, Sam

o-SAM-a-98 avatar Sep 30 '21 02:09 o-SAM-a-98

Good day Sam,

Did you find a solution to the issue? I'm having the same problem on my Sonoff POW R2 devices.

Inflames1981 avatar Oct 07 '21 07:10 Inflames1981

Me too

whizyrel avatar Oct 17 '21 13:10 whizyrel

A fix for this would be great!

sean-trace avatar Oct 27 '21 21:10 sean-trace

Here is a solution: https://github.com/skydiver/ewelink-api/issues/133#issue-775436153

bartwell avatar Nov 04 '21 19:11 bartwell

I followed https://github.com/skydiver/ewelink-api/issues/133 and got it to work most of the time. I found a bug in DevicePowerUsageRaw.get() that it cannot handle multiple websocket responses which occur sometimes. Below are changes that I made to fix it. With this, it works 100% of the time for me.

  • https://github.com/baugp/ewelink-api/commit/1034c56cf5e479d2c393d4bd5991592d5e6f5cbf

baugp avatar Nov 18 '21 08:11 baugp