i'd like to have a esp-01 powered on and controlled with a push button only. so imagine the device is off, the user press the momentary push button. in the setup the esp8266 turn on a mosfet or something similar to give himself power using another line. the user release the button and the device is on. i want to be able to understand long button press and double press and similar stuff too. even when device is already powered on. so i need to have a pin attached to the button somehow this is what i have till now, thanks to a very skillfull friend of mine
the vcc is 5 v and pin tollerance is only 3v
it must be completely off when not pressed for long battery duration