This calculator can be used to calculate LM317 resistor values from a needed output voltage or output voltage from given resistor values.
LM317 is a linear adjustable voltage regulator. It allows you to get lower output voltage from a higher input voltage.
Also, check out my newest calculator: Resistor Color Code – Value Calculator
How does the LM317 calculator work?
After typing in any two values of the three and pressing ‘Calculate’, the calculator will output the third value. If all three values are filled in – the calculator by default will calculate output voltage.
The calculator does additional checks on possible values. LM317, according to its datasheet, can output voltages from 1.25 to 37 Volts. Also, the calculator will calculate resistor heat output. If a resistor dissipates up to 0.4W of heat – it is a usable value. If it dissipates from 0.4 to 0.9W of heat – the text will be shown as a warning (yellow), because such heat output is high for such application. When a resistor dissipates more than 0.9W of heat – the text will be shown as an error (red), as the resistor will dissipate lots of heat.
Furthermore, resistor values should be positive values (R2 can be 0) in increments of 0.001. Note, that there is a small current flowing through Adjust pin. Because it is negligible, it was not used in any calculations shown at the end of this page.
Also, a good practice to choose R1 value between 100 and 1000 Ω (usually 240 Ω) . Input voltage needs to be at least 2V higher than output voltage to get good output regulation.
Theese are the formulas used for an output voltage, R1 and R2 calculation:
Vout = 1.25*(1 + R2/R1)
R1 = R2 / (Vout/1.25 – 1)
R2 = (Vout/1.25 – 1)*R1
Resistor heat output is calculated with a formula:
P(R1) = 1.25*1.25/R1
P(R2) = (Vout – 1.25)*(Vout – 1.25)/R2
You can buy LM317 ICs in TO-220 case via Aliexpress (affiliate link).
Also, if you want to read more about LM317 adjustable voltage regulator, its parameters, use cases, calculations or see more schematics with it, you can find this information in device’s datasheet here.
Furthermore, you can find more interesting blog posts here.