I would like to make a circuit that turns on a power supply to a microcontroller after holding down a button for a period of time (say 2 seconds). To make matters slightly more complicated, if possible, I would like to use this button as an input also. The power off could come from another switch if need be.
I was thinking of something like a latching RC circuit to an zener that switches a MOSFET on to allow power through. Ideally the solution would not consume power until the switch is pressed.
Thanks for any help