In the event, we need to build a variable DC power supply that output of 1A and can adjust up to about 30V.

Most people will use LM317 because of high-efficiency, easy to apply, and cheaper.

Is it really? You find out below.

**LM317 Datasheet**

It has an adjustable 3-terminal positive voltage regulator designed to supply more than 1.5 A of load current with an output voltage adjustable over a 1.2V to 37V range.

It has an internal current limiting, temperature detects shutdown and safe area compensation.

### LM317 pinout

**Figure 1: LM317 pinout on TO-220**

Look:

**Connection Diagram various LM317 Pinout**

LM317T on TO-220: output 1.5A

LM317L on TO-92: output 100mA

LM317K on TO-3: output 1.5A

LM317 on DPARK: output 1.5A

### Basic Features

- Output current in excess of 1.5A
- Output-Adjustable between 1.2V and 37V
- Internal Short-Circuit Current Limiting or Output is short-circuit protected
- Internal Thermal Overload Protection or Current limit constant with temperature
- Output-Transistor Safe Operating Area Compensation
- TO-220 Package like 2SC1061 transistors.
- There are 1% output voltage Durability
- There are max. 0.01%/V line regulation(LM317), and 0.3% load regulation (LM117)
- There are 80 dB ripple rejection

**Figure 2 the basic circuit diagram**

**Basic circuit diagram**

If the power supply filter has distance from IC-regulator too much. Tt should insert Ci to lower noise before IC-input.

Next in the figure circuit. The Co is not needs if you do not high-efficiency, but we put it better. It will keep lower an output ripple.

As Iadj is controlled to less than 100uA, the little error Unimportant in most applications.

The input voltage to the LM317 must be at least 1.5v greater than the output voltage.

## LM317 calculator

This **calculator** will work for most DC Voltage Regulators with a reference voltage (VREF) of 1.25. Typically, the program resistor (R1) is 240 ohms for the LM117, LM317, LM138, and LM150.

Some said Iadj is very low current.

So, we may reduce it down. To be shorter and easy.

Vout = 1.25V x {1+R2/R1}

Which is better?

For example:

You use R1 = 270 ohms and R2= 390 ohms. It causes output is 3.06V

Is it easy? If you have voltages choice with most resistors. In local stores near you.

look at the list:

### Output Voltage with R1 and R2 List

1.43V : R1 = 470Ω, R2 = 68Ω

1.47V : R1 = 470Ω, R2 = 82Ω

1.47V : R1 = 390Ω, R2 = 68Ω

1.51V : R1 = 330Ω, R2 = 68Ω

1.51V : R1 = 390Ω, R2 = 82Ω

1.52V : R1 = 470Ω, R2 = 100Ω

1.53V : R1 = 390Ω, R2 = 82Ω

1.56V : R1 = 330Ω, R2 = 82Ω

1.57V : R1 = 270Ω, R2 = 68Ω

1.57V : R1 = 470Ω, R2 = 120Ω

1.57V : R1 = 390Ω, R2 = 100Ω

1.59V : R1 = 390Ω, R2 = 100Ω

1.60V : R1 = 240Ω, R2 = 68Ω

1.63V : R1 = 330Ω, R2 = 100Ω

1.63V : R1 = 270Ω, R2 = 82Ω

1.64V : R1 = 390Ω, R2 = 120Ω

1.64V : R1 = 220Ω, R2 = 68Ω

1.65V : R1 = 470Ω, R2 = 150Ω

1.66V : R1 = 390Ω, R2 = 120Ω

1.68V : R1 = 240Ω, R2 = 82Ω

1.71V : R1 = 330Ω, R2 = 120Ω

1.71V : R1 = 270Ω, R2 = 100Ω

1.72V : R1 = 220Ω, R2 = 82Ω

1.72V : R1 = 180Ω, R2 = 68Ω

1.73V : R1 = 470Ω, R2 = 180Ω

1.73V : R1 = 390Ω, R2 = 150Ω

1.76V : R1 = 390Ω, R2 = 150Ω

1.77V : R1 = 240Ω, R2 = 100Ω

1.81V : R1 = 270Ω, R2 = 120Ω

1.82V : R1 = 150Ω, R2 = 68Ω

1.82V : R1 = 330Ω, R2 = 150Ω

1.82V : R1 = 180Ω, R2 = 82Ω

1.83V : R1 = 390Ω, R2 = 180Ω

1.84V : R1 = 470Ω, R2 = 220Ω

1.86V : R1 = 390Ω, R2 = 180Ω

1.88V : R1 = 240Ω, R2 = 120Ω

1.89V : R1 = 470Ω, R2 = 240Ω

1.93V : R1 = 330Ω, R2 = 180Ω

1.93V : R1 = 150Ω, R2 = 82Ω

1.94V : R1 = 270Ω, R2 = 150Ω

1.96V : R1 = 390Ω, R2 = 220Ω

1.97V : R1 = 470Ω, R2 = 270Ω

1.99V : R1 = 390Ω, R2 = 220Ω

2.02V : R1 = 390Ω, R2 = 240Ω

2.03V : R1 = 240Ω, R2 = 150Ω

2.06V : R1 = 390Ω, R2 = 240Ω

2.08V : R1 = 330Ω, R2 = 220Ω

2.10V : R1 = 220Ω, R2 = 150Ω

2.12V : R1 = 390Ω, R2 = 270Ω

2.13V : R1 = 470Ω, R2 = 330Ω

2.16V : R1 = 330Ω, R2 = 240Ω

2.16V : R1 = 390Ω, R2 = 270Ω

2.19V : R1 = 240Ω, R2 = 180Ω

2.23V : R1 = 470Ω, R2 = 390Ω

2.25V : R1 = 150Ω, R2 = 120Ω

2.27V : R1 = 270Ω, R2 = 220Ω

2.27V : R1 = 330Ω, R2 = 270Ω

2.29V : R1 = 470Ω, R2 = 390Ω

2.29V : R1 = 180Ω, R2 = 150Ω

2.31V : R1 = 390Ω, R2 = 330Ω

2.36V : R1 = 270Ω, R2 = 240Ω

2.37V : R1 = 390Ω, R2 = 330Ω

2.40V : R1 = 240Ω, R2 = 220Ω

2.44V : R1 = 390Ω, R2 = 390Ω

2.50V : R1 = 470Ω, R2 = 470Ω

2.57V : R1 = 390Ω, R2 = 390Ω

2.61V : R1 = 220Ω, R2 = 240Ω

2.65V : R1 = 330Ω, R2 = 390Ω

2.66V : R1 = 240Ω, R2 = 270Ω

2.73V : R1 = 330Ω, R2 = 390Ω

2.74V : R1 = 470Ω, R2 = 560Ω

2.75V : R1 = 150Ω, R2 = 180Ω

2.76V : R1 = 390Ω, R2 = 470Ω

2.78V : R1 = 270Ω, R2 = 330Ω

2.78V : R1 = 220Ω, R2 = 270Ω

2.84V : R1 = 390Ω, R2 = 470Ω

2.92V : R1 = 180Ω, R2 = 240Ω

2.96V : R1 = 270Ω, R2 = 390Ω

2.97V : R1 = 240Ω, R2 = 330Ω

3.03V : R1 = 330Ω, R2 = 470Ω

3.05V : R1 = 390Ω, R2 = 560Ω

3.06V : R1 = 270Ω, R2 = 390Ω

3.06V : R1 = 470Ω, R2 = 680Ω

3.08V : R1 = 150Ω, R2 = 220Ω

3.13V : R1 = 220Ω, R2 = 330Ω

3.14V : R1 = 390Ω, R2 = 560Ω

3.18V : R1 = 240Ω, R2 = 390Ω

3.25V : R1 = 150Ω, R2 = 240Ω

3.28V : R1 = 240Ω, R2 = 390Ω

3.35V : R1 = 220Ω, R2 = 390Ω

3.37V : R1 = 330Ω, R2 = 560Ω

3.43V : R1 = 270Ω, R2 = 470Ω

3.43V : R1 = 390Ω, R2 = 680Ω

3.43V : R1 = 470Ω, R2 = 820Ω

3.47V : R1 = 220Ω, R2 = 390Ω

3.50V : R1 = 150Ω, R2 = 270Ω

3.54V : R1 = 180Ω, R2 = 330Ω

3.55V : R1 = 390Ω, R2 = 680Ω

3.70V : R1 = 240Ω, R2 = 470Ω

3.82V : R1 = 180Ω, R2 = 390Ω

3.83V : R1 = 330Ω, R2 = 680Ω

3.84V : R1 = 270Ω, R2 = 560Ω

3.88V : R1 = 390Ω, R2 = 820Ω

3.91V : R1 = 470Ω, R2 = 1K

3.92V : R1 = 220Ω, R2 = 470Ω

3.96V : R1 = 180Ω, R2 = 390Ω

4.00V : R1 = 150Ω, R2 = 330Ω

4.02V : R1 = 390Ω, R2 = 820Ω

4.17V : R1 = 240Ω, R2 = 560Ω

4.33V : R1 = 150Ω, R2 = 390Ω

4.36V : R1 = 330Ω, R2 = 820Ω

4.40V : R1 = 270Ω, R2 = 680Ω

4.43V : R1 = 220Ω, R2 = 560Ω

4.44V : R1 = 470Ω, R2 = 1.2K

4.46V : R1 = 390Ω, R2 = 1K

4.50V : R1 = 150Ω, R2 = 390Ω

4.51V : R1 = 180Ω, R2 = 470Ω

4.63V : R1 = 390Ω, R2 = 1K

4.79V : R1 = 240Ω, R2 = 680Ω

5.04V : R1 = 330Ω, R2 = 1K

5.05V : R1 = 270Ω, R2 = 820Ω

5.10V : R1 = 390Ω, R2 = 1.2K

5.11V : R1 = 220Ω, R2 = 680Ω

5.14V : R1 = 180Ω, R2 = 560Ω

5.17V : R1 = 150Ω, R2 = 470Ω

5.24V : R1 = 470Ω, R2 = 1.5K

5.30V : R1 = 390Ω, R2 = 1.2K

5.52V : R1 = 240Ω, R2 = 820Ω

5.80V : R1 = 330Ω, R2 = 1.2K

5.88V : R1 = 270Ω, R2 = 1K

5.91V : R1 = 220Ω, R2 = 820Ω

5.92V : R1 = 150Ω, R2 = 560Ω

5.97V : R1 = 180Ω, R2 = 680Ω

6.04V : R1 = 470Ω, R2 = 1.8K

6.06V : R1 = 390Ω, R2 = 1.5K

6.32V : R1 = 390Ω, R2 = 1.5K

6.46V : R1 = 240Ω, R2 = 1K

6.81V : R1 = 270Ω, R2 = 1.2K

6.92V : R1 = 150Ω, R2 = 680Ω

6.93V : R1 = 330Ω, R2 = 1.5K

6.94V : R1 = 180Ω, R2 = 820Ω

7.02V : R1 = 390Ω, R2 = 1.8K

7.10V : R1 = 470Ω, R2 = 2.2K

7.33V : R1 = 390Ω, R2 = 1.8K

7.50V : R1 = 240Ω, R2 = 1.2K

8.07V : R1 = 330Ω, R2 = 1.8K

8.08V : R1 = 150Ω, R2 = 820Ω

8.19V : R1 = 270Ω, R2 = 1.5K

8.30V : R1 = 390Ω, R2 = 2.2K

8.43V : R1 = 470Ω, R2 = 2.7K

8.68V : R1 = 390Ω, R2 = 2.2K

9.06V : R1 = 240Ω, R2 = 1.5K

9.58V : R1 = 330Ω, R2 = 2.2K

9.77V : R1 = 220Ω, R2 = 1.5K

9.90V : R1 = 390Ω, R2 = 2.7K

10.03V : R1 = 470Ω, R2 = 3.3K

10.37V : R1 = 390Ω, R2 = 2.7K

10.63V : R1 = 240Ω, R2 = 1.8K

11.25V : R1 = 150Ω, R2 = 1.2K

11.44V : R1 = 270Ω, R2 = 2.2K

11.48V : R1 = 330Ω, R2 = 2.7K

11.67V : R1 = 180Ω, R2 = 1.5K

11.83V : R1 = 390Ω, R2 = 3.3K

12.40V : R1 = 390Ω, R2 = 3.3K

12.71V : R1 = 240Ω, R2 = 2.2K

13.75V : R1 = 330Ω, R2 = 3.3K

15.31V : R1 = 240Ω, R2 = 2.7K

16.25V : R1 = 150Ω, R2 = 1.8K

16.53V : R1 = 270Ω, R2 = 3.3K

16.59V : R1 = 220Ω, R2 = 2.7K

18.44V : R1 = 240Ω, R2 = 3.3K

19.58V : R1 = 150Ω, R2 = 2.2K

20.00V : R1 = 220Ω, R2 = 3.3K

23.75V : R1 = 150Ω, R2 = 2.7K

24.17V : R1 = 180Ω, R2 = 3.3K

28.75V : R1 = 150Ω, R2 = 3.3K

For example, you need 4.5V from AA 1.5Vx3 in a series. But you do not have them. How to do? You have only LM317 and a lot of resistors. Yes, It can use it instead.

Look at the list above in 4.5V voltage we can use R1 = 150Ω, R2 = 390Ω.

It is easy, right?

### LM317 heat sink calculator

What is the size of the heat sink enough?

While The LM317 is running. It is so hot. Though it has an over-temperature cut-out. But we do not need it hot. We always install the heat sink.

Someone ask me. How much should you use the smallest heat sink? LM317 has a maximum temperature of 50 °C/W without a heat sink.

I found this site good with the LM317 heat sink calculator.

*You can find the LM317 on Amazon here if you’re interested.*

## For example LM317 circuit

**First**Variable DC Power Supply

It is my first power supply that I built. Though very old still using more than 20 years. Why it is great?**Linear Selector Power supply Regulator**

It’s easy to select voltage output 1.5V, 3V, 4.5V, 5V, 6V, 9V at 1.5A**30V Dual DC variable power supply**

It’s high volt (0-60V) at 1.5A and starts voltage at zero! good job.**Great****DC power supply**

High quality, 3A adjustable voltage regulator. Using LM317 and 2N3055 so easy and cheap. Adjust voltage in steps 3V, 6V, 9V, 12V. And In fine, 1.25V to 20V.**4 Lead Acid Battery charger circuits**

See 4 LM317 Lead-acid battery charger circuits for 6V, 12V, and 24V battery. With automatic charging and full charged Indicator using TL431. Easy to build.**Dual power supply 3V,5V,6V,9V,12,15V**

Dual power supply circuit,can select voltage levels 3V,5V,6V,9V,12,15V at 1A and -3V,-5V,-6V,-9V,-12V,-15V at 1A, use LM317 (positive) LM337(negative) […]**USB Battery Replacement**

This is a USB 5V to 1.5V Step-Down Converter Circuit. When we use a Cheap MP3 Player which uses only one 1.5V AA battery as its power supply.**Low dropout 5v regulator**

This is 5V low dropout regulator circuit using a transistor and LED only so easy,lowest voltage input is 6V so across it is 1V only, make output is 5V 0.5A**Gel cell battery charger circuit**

It can charge any size of the Gel cell batteries and extend the life of the Gel Cell battery. While the circuit is running, the LED indicates charging.**Nicad Battery Charger using LM317T**

Here are Universal NiCd and NiMH battery charger circuit. It uses IC LM317T ( Hot IC) Control Current less 300mA, Size battery 2.4V,4.8V,9.6V. Low-cost circuit

### Related Posts

## GET UPDATE VIA EMAIL

I always try to make Electronics **Learning Easy**.

## worku

26 Jan 2016Thank’s & GBU this EC member .

## vishal

2 Feb 2016sir i want 5v,2a power supply circuit with calculation from 230

## sunday owen

12 Jun 2016pleasr can this idea be used to build solar charge controller?

## Sumithra

20 Jul 2016Pls suggest any simple circuit which supplies output of +12V , -12V dual output with current rating of 1A

I/p supply is +24V DC .

## CHRISTOPHER SILWAMBA

10 Sep 2016IAM LEANING A LOT I THANK VERY MUCH OUT OF THE MANY THINGS U ARE REVIEWING.

## Abiodun Ogundipe

4 Aug 2017Dear Sir/Ma

We are spare part supplier in Nigeria,

Company name with address

DE- ACCORD SYNERGY CONCEPT NIG LIMiTED. NO6, Oba Amusa Avenue Sumbol Bus Stop, Lagos Nigeria.

Kindly quote us for the bellow items for our customer.

LM78S40 (Universal Switching Regulator) 2nos

LM7805 (Voltage Regulator) 2nos

Your best price and delivery

Best Regards

Abiodun Ogundipe

+23435766398

## KUMERASAN

1 Jul 2020sir i want a simple voltage regulator for increasing and decreasing the small halogen bulb

input voltage is 12v AC and out put 6v dc with variable pot using matal cap transistor like LM317K.

## Apichet Garaipoom

12 Aug 2020Hello, Kumerasan

Thanks for visiting.

It is a good idea. Let me give you a comment. What is the small halogen rate, current or watts? Here is 5watts https://amzn.to/2XTskJm

It uses current about 5W/6V = 0.8A. Yes, you can use LM317. It may very heat. But if you use 10W. It will use current more = 10w/6V = 1.6A.

You cannot use alone LM317. You may use it with a power transistor. Or use LM350. It is easy, too. https://www.eleccircuit.com/lm350-adjustable-voltage-regulator/

I hope this can help you.

Ps. I also had the idea of using hydrogen tubes for my chickens.

Do have chickens?