Once you've decided on batteries, how do you regulate the voltage?
| Attachment | Size |
|---|---|
| DSE200405_catalogue_data.pdf | 1.02 MB |
| LM2940CT-5.pdf | 409.32 KB |
| LM7805.pdf | 1.7 MB |
Recently I've noticed some people are a bit unsure of how to regulate their robots batteries and since there was a tip/walkthrough on batteries recently I though this might be a good time to explain voltage regulation. Since robots and their power requirements vary so much I've presented several general purpose schematics showing different configurations. These should work with most of the robots I've seen on this site. Note that a heatsink should be used on the regulator. I've attached data sheets for the regulators.
To begin with the most common configuration is a battery with a voltage greater than 5V and a simple 5V regulator.

I've notice many people use a 9V battery so that is what I've shown here. The large electrolytic capacitors (470uF) help the regulator deal with big surges in power such as a heavy load being turned on. The smaller capacitors help filter out noise and spikes. This setup cannot produce a lot of current due to the battery. A 8.4V NiMh or NiCd rechargeable battery is the way to go here as it saves you money and can usually deliver more current for longer.
This setup isn't very efficent because up to 4V is dropped across the regulator. If your circuit is drawing 100mA at 5V then it uses 5x0.1=0.5W of power. If you are using a 9V then 4V at 100mA = 0.4W is wasted as heat by the regulator and a small heatsink may be required. Once again the rechargeable is a better choice as it will only waste 0.34W of power.

This is a more efficent design that can deliver more power. It also has a 6V output for servos, motors, relays etc. You can use 4xalkaline batteries or 5xNiMh. I recommend 5xNimh as they last longer and the voltage stays at 6V almost to the end where as the alkaline batteries will steadily drop in voltage. I've used a low dropout regulator for efficency. The popular 7805 needs the input to be at least 2.5V higher than the output for reliable opperation. This LM2940CT-05 will work reliably with an input just 0.5V higer than the output. As I mentioned before, the more a regulator has to drop the voltage the less efficent it is.

This is another variation using a popular 7.2V NiCd or NiMh battery pack from a radio controlled car. This circuit gives you 7.2V for bigger motors. I've used two power diodes in series to give you a 6V supply for servos. Each diode will drop about 0.6V and will handle up to 1A, together they drop aprox. 1.2V. If you need more than an amp for servos then bigger diodes can be installed. You may want to install a fuse as well since those battery packs can put out a lot of current if a motor stalls.

This is a typical setup with two batteries. I've shown a 12V car or SLA battery as might be used in a big robot like Walter. I've also shown a 9V as in some cases a 9V supply can be handy for op-amps. You can use whatever batteries suit your needs. The batteries shown in these circuits are just typical examples.

These are typical capacitors I use in my circuits.
I've shown them here for those who are uncertain what capacitors to use.
At the top you can see two electrolytic capacitors. These capacitors may be a different colour but will always have the polarity marked on them. Note in the photo that a negative symbol is shown in an arrow pointing to the negative lead. Usually the negative lead is a bit shorter than the positive as well. They also have a voltage rating on them. Never exceed this or connect them the wrong way around as the can leak a foul substance.
The next down is a greencap, polyester or mylar capacitor. They are not always green but reguardless of their name they work the same. The capacitor in this picture is a 0.1uF and could be used in the above circuits. This capacitor is not polarised (no plus or minus) and is rated up to 100V.
The smaller grey capacitor below is a modern equivalent called a MKT or minature polyester. It is the same as the greencap above in value and voltage rating but noticably smaller.
At the bottom is a monolithic capacitor which is what I tend to use these days. The capacitor in the picture is also a 0.1uF and non-polarised. It has a rating of 50V.
I've attached a general purpose datasheet from Dick Smith Electronics that has good information on electronic components in general including a section on regulators.
Finally a brief mention on DC-DC converters. As mentioned above, the more voltage a regulator has to drop the less efficent it is. When you need to use higher voltage batteries such as the 24V I use for BoozeBot then regulators are bad news. They can deal with input voltages in excess of 30V with suitable heatsinks but to get 5V at 1A from a 24V battery means 19W of power would be wasted as heat to give me 5W of usable power or just over 20% efficency. This is where DC-DC converters are well worth the money as they are usually 80%-90% efficent depending on load and design.
This photo shows the 3 DC-DC converters used in BoozeBot. The two converters at the top are kits I bought and assembled. They can put out in excess of 2A each. The 6V output is regulated down to 5V where necessary and the 9.5V output is for an ASUS Eee-Pc. These kits were reasonably priced and because you make them yourself they can be setup to produce almost any voltage. Both of mine reduce the voltage but they can be made to increase the voltage as well. At the bottom is a bought unit. It can produce about 10A and will run BoozeBots arm motors.
I hope this information is helpful. Good luck and enjoy!





@ Fri, 2012-05-11 02:12
thank you
thank you
@ Wed, 2012-05-09 14:31
Unable to get LM2940CT-5
I am unable to get the LM2940CT-5. Is there any other voltage regulator similar like this. I am using the 3rd Schematic and my power source is 6 NiMH Batteries.
@ Thu, 2012-05-10 09:50
There are many LDO regulators available.
LDO stands for Low Drop Out. These regulators are more efficient when the input voltage is only slightly higher than the output. Another one I have used is the L4940V5. Using a suitable heatsink this regulator will handle up to 1.5A.
If you need more current then the LM1084-5 is rated for 5A but you will need a bigger heatsink as this is still a linear regulator. The dropout voltage of this regulator is about 1V at 1.5A and increases to 1.3V at 5A although these values improve slightly as the regulator warms up.
Just Google "LDO regulator datasheet" and see what else is available or else look for "LDO" when going through electronic catalogs of various companies.
@ Mon, 2012-04-30 17:31
Hey, Can I use a 7.4V Lipo
Hey, Can I use a 7.4V Lipo 2200mAh Battery from DFRobot with any of these schematics?
@ Mon, 2012-04-30 19:10
That should be fine.Just
That should be fine.
Just follow normal precautions for charging your LiPo batteries.
@ Tue, 2012-05-01 18:45
Thanks for the reply, but I
Thanks for the reply, but I have a small doubt. The DFRobot's 7.4V Lipo 2200mAh Battery (Arduino Power Jack) had a text saying " The latest version has buildin protection board which allows the battery to be charged by 9V DC power supply. You don't need professional battery charger any more". That means can I charge the LiPo with a 9V DC power supply? If yes, then could you please help me how to charge it.
@ Tue, 2012-05-01 21:12
I'm merely saying that a
I'm merely saying that a LiPo battery can be used to provide a power source for the above circuits. My off-hand mention of safe charging was just in case you are unfamiliar with charging LiPo batteries.
Your follow up question is pretty far off topic for this post, and very specific to your battery. If you have a question about how to charge your battery, and you don't understand the documentation, post a separate forum question about it.
@ Mon, 2011-06-27 21:02
Thanks for taking the time
Thanks for taking the time to educate some of us!
@ Tue, 2011-06-28 10:39
Alway happy to help. It's
Alway happy to help. It's great to see so many people making robots.
@ Wed, 2011-04-13 20:05
Thank you all for your
Thank you all for your comments, hepled a lot. How do I know the maximum safe voltage for my motors if they dont have any info printed on them or I dont want to take the mechanics apart? For example the RC car drives from a 6V battery. I just want a little more power, can I drive it safely with 7.2V or even 9V ? I.e. is 20-30% more voltage OK for toy DC motors?
Second question would be on how to know when the battery dies? I want to have the speed of the robot as constant as possible. I.e. if I go PWN 200, I want to be sure the speed will be the same for the whole trip, and not slowing down because the battery is dying. Thank you all for your help