I have searched and seen some topics about this, but couldn’t make it work for my scenario.
I have an Ethereum miner connected to a Wemo switch. When it freezes the wattage drops to about 350. So, I want the switch to turn off, sleep 30, turn on when wattage drops below 400 for 30 seconds.
I’ve made an automation in the GUI. The condition and action was easy, but I have problems with the trigger. I’ve figured I need to create a template, but I don’t understand how and how I include it in the automation. So that’s what I need help with =)
Is it healthy for your rig to cycle power that way? Also, what is the power draw like during the restart/boot-up window? You have to be careful that it’s not under 400 watts, because then you might get in an endless wemo bootloop. Consider increasing the time limit under for: .
That looks like what I want, yes. I tried the same, but without the value_template
Yes, it’s safe to do this. And 30 sec is just enough to reboot and start the miner program (850w).
However, if it doesn’t manage to start the program and gets stuck in a loop it would probably not turn on at all after a few cycles due to over charged capacitors. I will have to try and find the optimal time, for sure. I’ve configured it to email me when it freezes as well, so I can reboot it manually, so this is just to save me some hours if it freezes during the night.
I’ve configured the trigger, and will test during the day!
As a note, I did similar except I wrote a script that scrapes my hash rate from my pool. If it is below a threshold for a period of time I send a push notification. I have debated just adding the outlet and then power cycling from that same automation. I didn’t know the Demo smart plugs provide power usage. That would be great to track for mining rigs for sure. I currently use a Kill-A-Watt for calculating power usage.