Set countdown timer on plug? #284
-
I know that there is a branch that has made some progress on implementing schedules. If it is possible yet, I was wondering if any of you wizards could provide an example script to add a countdown timer to power off a plug after 1 minute. My hope is to run it during shutdown on my raspberry pi, so that it can be automatically powered off after safely shutting down. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
So I just checked how this works on KP115, and from the looks of it there can only be a single countdown timer and they do not get removed automatically... However, here's what you could do using raw commands to achieve your goal:
Note down the rule id or perform a query to list available rules, you will need this to modify the rule to activate it later.
The action will be run after the timer expires, and it will get disabled. You can re-run the same |
Beta Was this translation helpful? Give feedback.
-
I'm getting an error on a HS110(UK) plug when I try it, does anyone have any thoughts on how I can resolve? ./kasa --host 192.168.1.3 raw-command count_down add_rule '{"enable": 0, "delay": 5, "act": 0, "name": "test"}' |
Beta Was this translation helpful? Give feedback.
So I just checked how this works on KP115, and from the looks of it there can only be a single countdown timer and they do not get removed automatically... However, here's what you could do using raw commands to achieve your goal:
Note down the rule id or perform a query to list available rules, you will need this to modify the rule to activate it later.
If you get an error on already existing rule, you can either delete this by using
dele…