-
Notifications
You must be signed in to change notification settings - Fork 296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Which command to get the runtime values and statistics? #12
Comments
Yo man, if you use the info command, you'll get a response where among the stuff returned, you'll find "on_time" which shows how many seconds the device has been running since it was turned on. If there's a command missing, you can find the commands by using a network monitoring app on your phone to check what commands Kasa is sending, then you can use the python script to send the same commands that you found through the network monitoring app. |
@PatrickBB29 - I don't have access to mine at the moment, but IIRC, current is in amperes. It should be a float. (This should let you do P = I x E, but maybe only for a straight resistive load. I did some testing with a space heater.) IIRC the device is uploading samples to Kasa's cloud service. So if you wanted to do it locally, you'd need to periodically poll and accumulate the values into the desired buckets. Have you seen the Reverse Engineering blog post? There is a lot of info in there. While the focus is security, there is quite a bit about how the device functions. There might have been a way to change the URL the device posts to, though ssl certificate might be a problem. |
Hi, |
Hi, Finally, with a load multiplied by almost 6, current only increase by almost 3. P <> U x I /1.414 (accounting for efficient voltage of a sinusoidal power supply 2^0.5=1.414) Neglecting cosine effects on the power I might be all wrong, so have a look as well |
Hi @PatrickBB29 , I saw your thread and I had similar question. How do I get the total runtime of the machine that is connected to the smart plug? For example I have a TV connected to it and I want to know how many hours have the TV switched on for a day, a week perhaps a month? Not the switch on time of the smart plug. Any solutions? Regards, |
Hi,
using Kasa application, it's possible to get information about energy usage and also about runtime.
I don't find the command to get these statistics (Current runtime, Total runtime, day or month stats about runtime).
Is there any missing commands in the file "tplink-smarthome-commands.txt"?
Other question, the command -energy ( {"emeter":{"get_realtime":{}}} ) gives a value for a parameter named 'current'.
Do you know what the 'current' data is, what is its unit?
Many thanks,
Patrick
The text was updated successfully, but these errors were encountered: