hi all
i want to put a momentary push button (binory sensor) at my door that when leaving the house it will turn off any lights or devices that are currently in the on state. Then when i get home i want to press the same button again to turn on certain lights and devices.
With it being a push button how would i configure this in an automation? i would like to use esphomelib, however a push button wont have a state of ON or OFF, is that correct?
i have the same scenario currently for switching individual lights on and off but this is just using a toggle command, so it doesnt need to be as intelligent as an home or away push of the button.
Is there something simple to achieve this and any examples greatly appreciated
cheers