sampsyo / wideq

reverse-engineered client for the LG SmartThinQ API
https://pypi.org/project/wideq/
MIT License
333 stars 158 forks source link

add power readings to ac_config #77

Closed dacrypt closed 4 years ago

dacrypt commented 4 years ago

This is to address #75

sampsyo commented 4 years ago

Looks pretty cool overall! Any chance you could try giving these two properties more informative names? TBH I have no idea what “inout total power” means... or what units they’re in. We can pick more meaningful names than LG did!

gladhorn commented 4 years ago

The flake8 issue should be fixed now :)

dacrypt commented 4 years ago

@sampsyo is that ok or should I return just the value and not the whole json returned by lg?

sampsyo commented 4 years ago

Yeah, absolutely; returning an actual integer instead of the JSON object would definitely be more useful. In general, the idea with wideq.client is to be a sensible wrapper that programmers would actually want to use—not to faithfully reflect the LG API, which is usually pretty incomprehensible.

Is that what the current state of the code does, or do we need to add a field access to those methods?

dacrypt commented 4 years ago

ok, that should do it. let me know

dacrypt commented 4 years ago

Looks good! One tiny suggestion within. I can't test this because my units don't support it, but if you have tested and it looks good to you, let's merge.

it seems to be reporting fine. You can go ahead and merge it

sampsyo commented 4 years ago

Awesome.