Step 10: LM317 Voltage Regulator

In order to be able to provide enough power for our servos, we need to have a separate power supply since the Arduino cannot supply the servos with enough current. The voltage range for these servos is around 5V. Since most batteries are not 5V we need to use a voltage regulator.

The LM317 is an adjustable voltage regulator that you can change to fit your power supply. You can find the datasheet for the LM317 here. We will be using the same circuit as on page 9.

The important part for the LM317 voltage regulator is to adjust the 5k trimpot so that the output voltage is at 5V. The LED can be used as a visual indicator for the voltage. If the LED is extremely bright or burning up, then you may have too much output voltage and your servos may be at risk.

Depending on how much higher your supply voltage is compared to 5V, there may be a considerable amount of heat generated. In this RoboBrrd, I am using 11.1V, which means the LM317 heats up quickly. I use a medium sized heatsink to help dissipate the heat.

On the proto-screwshield we want to design for maximum fixability. Therefore, we use female headers for the LM317 to plug into in case of the unlikely event that the LM317 stops working and we need to replace it.
Frank Buss3 years ago
Your instructable is very detailed, but I think this step is not easy for beginners to follow. The schematic with the 2 protection diodes is on page 10 in the datasheet, not page 9 and it is difficult for beginners to see how the parts are connected, if they are not used to read datasheets, e.g. the right polarity of electrolytic capacitors and the connection of the LM317. It is not the circuit you are using, but I think this a good example how it could look like: http://laserpointerforums.com/attachments/f42/31562d1298103794-diy-homemade-laser-diode-driver-31410d1297294173-logical-way-setup-2x-lm317-driver-lm317.jpg