scottbonline / sense

Sense Energy Monitor API
MIT License
174 stars 45 forks source link

Real-time Watt and DeviceID for active_devices #12

Closed therealmysteryman closed 6 years ago

therealmysteryman commented 6 years ago

Started using your Library to create a interface between device ISY994i and the Sense API.

There two things that I would like to see and not sure if it already there and didn't see it or available on the Sense API. It would be to get the current watt usage of a device ? I see I can get the average but not the real-time value.

Also on the active device, do you know if you could also get the device id ? As name can change and would be difficult to link them back to the proper device id ?

therealmysteryman commented 6 years ago

Strange, not sure if something I changed on the sense API side, but I not getting any real time report since Saturday Morning. The function active device return empty array.

scottbonline commented 6 years ago

hmm just tried and it seems ok

(pyvienv)  ~/code/sense/sense_energy   stable  python sense_api.py
Please enter you Sense username (email address): 'sdfgsdfg'
Please enter your Sense password:
('Active:', 916.9664306640625, 'W')
('Active Solar:', 0, 'W')
('Active Devices:', u'Other, Always On')
therealmysteryman commented 6 years ago

It worked the first day and stop working here my output

Please enter you Sense username (email address): 'xxx@gmail.com' Please enter your Sense password: ('Active:', 0, 'W') ('Active Solar:', 0, 'W') ('Active Devices:', '')

scottbonline commented 6 years ago

Let me take a look later today at exposing the device id’s (they are buried in there) and see if the active stream blob has them in there.

Not sure about the 0% util though as I can’t seem to reproduce it. What build are you on? Does the web gui and/or phone app show it correctly?

therealmysteryman commented 6 years ago

I'm using the stable sense_energy 0.3.0 release installed from pip3. Everything is working normally in the app, I see activate device and current usage. It worked the first days and then it stop. Not sure if there a command I can run for helping debug the issue ?

therealmysteryman commented 6 years ago

I could always provide you with my credential for testing purpose... but yeah can get to give me the actual anymore.

scottbonline commented 6 years ago

I’m out of town this week, but will be back in a couple days to dig into this

therealmysteryman commented 6 years ago

No problem :)

scottbonline commented 6 years ago

ah confirmed not working, investigating

therealmysteryman commented 6 years ago

Perfect Thanks

scottbonline commented 6 years ago

should be working now, @kbickar to the rescue!

therealmysteryman commented 6 years ago

Yes fixed, Thank you both !