Electronics > Electronics

One battery or two?

(1/2) > >>

ErikY:
I am designing a circuit for an ATmega328P to control Dynamixel servos.

I want to run 12Volts to the servos, to give them the power they need.

My question is, should I run the same 12 volts through a 5V regulator for the ATmega328p, or should I use a second say 6Volt battery  for the Atmega?

MrWizard:
Separate batteries are always better.

ErikY:

--- Quote from: MrWizard on December 10, 2012, 03:23:10 PM ---Separate batteries are always better.

--- End quote ---

Thanks for the response, just so I understand, is it significantly better, or just a bit better?

MrWizard:
To give the mcu a steady and stable current is keeping strange malfunctions out.
Servo's, dc motors, etc are not giving a stable current, because they start, stop and reverse giving a peak/spike/jitter, which can affect the mcu, the more things attached, the more draw. So you can take the voltage down so much that the mcu reacts different. With 2 small servo's there is not too much problems, but bigger, stronger, quicker is asking for problems.

jwatte:
Managing two batteries is a pain. Charging them separately, one running out while the other still has juice, etc. I have this problem on my rover with the old, RC-truck based design, and I will be switching to shared power for the re-build.

Any decent voltage regulator will be able to compensate for the voltage spikes. (Note: 7805 isn't particularly "decent" these days -- very old design.) Put something like a 1000 uF electrolytic capacitor in front of the regulator, perhaps with a fast diode in front of it to provide some additional sag protection, and a 100 uF electrolytic and a 4.7 uF ceramic after the electrolytic, and you'll do fine. Warning: read the data sheet for your regulator -- some regulators have specific requirements on capacitance (not too high, or not too low.) The LM350 has ripple rejection of 86 dB, but requires an idle current and adjusting resistor divider. The LF50ABV has > 80 dB ripple rejection, has ultra-low drop-out (0.35V or so) and has been very stable for me.

Or use a switch-mode power converter for more efficient voltage conversion. Those will almost entirely de-couple you from input spikes (at the cost of some generated output ripple.) Either a hobby-RC UBEC (warning: quality may be spotty) or something like the converters from Pololu, or some DC DC power converter module from digi-key or mouser or similar.

If you REALLY care, put a 10 uH 1A inductor followed by another 100 uF capacitor after the regulator, and you'll have power so clean you could drive a stereo pre-amplifier with it :-) Another option is to use a switch-mode to take it to 5.5V, and the the ULDO regulator for a rock-stable 5.0V, with about 85% efficiency (depending on efficiency of the switch mode regulator.) This is a very clean power section:



Most microcontrollers have de-coupling capacitors mounted right at the uC, though, so a simple voltage regulator plus capacitor combo is probably all you need.

Navigation

[0] Message Index

[#] Next page

Go to full version