Hi folks - trying to come up with the best way to handle this. I have a widget plugged into a wall socket and when power is shut off to that socket I need to send a shutdown command elsewhere, wirelessly. The basic component s already complete, except for knowing when to send the shutdown. One option is using capacitors to buffer enough power for a shutdown command then detecting the power loss, another is adding battery backup and detecting the switch to battery. Any other ideas or implementations of this idea? I have to be alive long enough to get a confirmation back of the shutdown msg I sent out, so it could be several seconds worst case.
I'm thinking battery is the best way since it fulfills more use cases, but I am hoping someone has expertise in this area already!