To keep my electricity bills down, I’ve created this to encourage my family to use the dishwasher only when my solar panels are producing power. It’s connected to a smart plug (I’m using a Samsung ST one).
The piston turns on the plug an hour after sunrise and turns it off an hour before sunset. This serves as a proxy for solar energy production (my inverter isn’t smart enough for anything better). If the dishwasher is running, the piston will wait until the cycle is complete before turning off the plug. We often load the dishwasher in the evening and turn it on. It will only actually start when the piston turns on the plug the next morning.
It’s quite simple: just define a plug to use and a power threshold to tell the piston that the device is running.