Transistor + Arduino (Extream sleep mode of 0mA)

Is there a way to switch on and off the arduino with a simple button and a transistor?

I came out with the following schematic (attachment).
(on) Would be an output PIN of VCC when the arduino starts (so you don’t need to keep pressing the button, because the arduino does that job)
(off) Would be a input PIN, that detects when you press the button again.
(diode) avoids the current to flow back (when the arduino takes care of the transistor), so you can basically press the button to switch it on and off.
(Orange button) Is the button that works to switch on and off

I had to made some modifications but the idea is here, i might post the source and the entire schematic, but after i tested it out, the consumption is 0mA (yes zero!!)

esquema.png

To turn it on, the button has to be pressed until the bootloader is finished and the Arduino takes over to turn the transistor on ?

I like the idea, it will even work with a full board.
For power saving, a standalone is used, but with your circuit any Arduino board will do.

You say 0mA, but I don't care about milli Amperes. I want to know how much µA.
Nick Gammon has it down to 4.4µA : Gammon Forum : Electronics : Microprocessors : Power saving techniques for microprocessors

Need a resistor from gate to battery to hold the part in off state when arduino stops pulling the gate low.

Thank you guys for your feedback

CrossRoads:
Need a resistor from gate to battery to hold the part in off state when arduino stops pulling the gate low.

Wouldn't that spend Amps?

If you use P-channel MOSFET, the base is voltage driven, current is very very low.

CrossRoads:
If you use P-channel MOSFET, the base is voltage driven, current is very very low.

Sorry but what's that "Q" component?

Isn't there a problem with all these circuits?

You need to remember that if you disconnect the Vcc rail from the supply an Arduino's
pins will all be at ground, so they will pull a PNP or p-channel ON immediately.

And if you do low side switching the converse situation is true, all the Arduino pins are
at Vcc and will turn on any NPN or n-channel switch.

To get this sort of power switch you are best doing it with a CMOS flip-flop circuit, use
the button to switch on, and an Arduino pin to switch off.

Q is the MOSFET, logic level, Low Rds P-channel or N-channel.

I could see adding open collector NPN then to pull the gate low.

Yes, that circuit should do fine. (source and drain are mis-drawn though)

Gak - I can never get that one straight. It's upside down?

Pololu has a nice little MOSFET pushbutton power switch that seems to do just what you want: http://www.pololu.com/category/121/pololu-pushbutton-power-switches

p-channel is the same of a transistor?
What's the difference?

P-channel MOSFET vs PNP transistor.

PNP transistor will have a somewhat fixed drop from Collector to emitter, 0.5 to 0.7V.

P-channel MOSFET will have a somewhat fixed resistance from drain to source, and the voltage will vary with current.
So this part for example
http://www.digikey.com/product-detail/en/NDP6020P/NDP6020P-ND/1055922
with 50mOhm (milliOhm) Rds will have just 0.05V across it with 1A of current flow.
MOSFETs also need very little current to turn on & off, while NPNs/PNPs can need tens of mAs to switch larger currents on & off.
That voltage drop can be important when driving motors for example.

Ok, thank you so much.
Also i have to say that i can see that you are a dedicated member, thanks and keep up your nice work

Roger that.