broadlink-java-api icon indicating copy to clipboard operation
broadlink-java-api copied to clipboard

[Patch] Read Power Consumption from SP2/SP3 devices

Open KiralyCraft opened this issue 6 years ago • 0 comments

https://pastebin.com/kidagDLn

I'm too lazy to do this properly, here is a quick thing to add in the SP2Device class that allows reading of power consumption. Returns exactly the same values as in the app.

Also, for some reason, my SP2 plugs return this as their model: -27526 I had to add it manually in BLDevice to force it to create an instance of it. It's written "SP3" on my plugs but they work with SP2 api so who knows.

The patch above works for my specific plugs, SP3, european style connector: https://2.bp.blogspot.com/-idwScYkor94/WJWdYcM1LEI/AAAAAAAAFvE/MapfzRuCQX8Ift1eqLiDlrSnRo1modgLQCLcB/s1600/Broadlink-SP3.jpg

KiralyCraft avatar Nov 14 '19 22:11 KiralyCraft