Battery hookup to arduino - Power switch

Hey there,

I'm doing a project I want to make portable so I'm getting a 6*AA holder and i'm wiring it in to a 2.1mm barrel jack which isn't a problem but I wanted to make a power switch. I have an on/off toggle switch spare (2 prongs on it) and I was wondering would it work just to have it on the positive line?

Essentially: Battery holder with +ve and -ve, -ve going straight to ground terminal on the barrel jack but +ve going to one prong on the toggle switch then the other prong to the +ve terminal on the jack.

Would this work?

I guess as long as you break the circuit it will work. There are probably safety things to consider like rating of the switch to ENSURE it breaks the circuit...but

  1. They may not be required at all...I'm new here myself!
  2. If they ARE required, they probably vary from country to country in terms of regulations.

Good luck!

Yes, just connect the switch in series with the + wire.

If you connect +batt to V-in (assuming you have an Uno), then your battery could last a bit longer. Because there is a reverse polarity diode with a 0.7volt drop between the DC socket and V-in. Disadvantage is that you loose reverse polarity protection, so take care when changing batteries. Leo..

Well the idea of the switch is to cut the power when not in use, it's a breathalyzer project so the alcohol sensor is pretty power hungry on it's own, I don't think the slightly less battery consumption is too much of a worry so the DC will be fine, thanks for that info though, could be very handy in further projects!

Thanks for the answers guys, I really appreciate it!

Just be careful about connecting live external components to a dead MCU.