LM338 Regulator - how to calculate value of resistors

Discussion in 'General Electronics Chat' started by amateur_24, Apr 28, 2011.

  1. amateur_24

    Thread Starter New Member

    Oct 28, 2010
    I'm a little confused how the formula works. My answers are completely wrong. I'm trying to make a 1 - 15v PSU. I'm using a power brick from an old laptop. Capable of 90w of power at 19v.

    According to the ds I use the following

    1.25v (1+R2/R1) + I(ADJ) * R2

    My math is very rusty lol. Please show your working out.
  2. Wendy


    Mar 24, 2008
    I believe it is similar to this circuit (note, this is a positive voltage regulator). The math is the same though.

  3. amateur_24

    Thread Starter New Member

    Oct 28, 2010
    Hi Bill,
    May I ask what's the +ADJ*R2 bit for? I noticed the example you gave me doesn't have it.
  4. Jaguarjoe

    Active Member

    Apr 7, 2010
    The total current through R2 is the current through R1 plus the current out of the I(ADJ) pin. Normally, the current through R1 is set at 10ma to satisfy the regulator's minimum load current (from the ds). The current out of the I(ADJ) pin is 50ua (from the ds). Both of these currents would be used to determine the value of R2 but I(ADJ) is so small in relation to the other 10ma flow (200x smaller) that it is usually ignored.
    The voltage across R1 is fixed at 1.25v (from the ds). The current was picked to be 10ma, so R1 = E/I = 1.25/.01 = 125 ohms.
    Plug all of this into the main Vout equation for an output of 15v:
    Vo = 1.25(1 + R2/R1)
    15 = 1.25 (1+ R2/125)
    15/1.25 = 1+ R2/125
    12-1 = R2/125
    11*125 = R2
    R2 = 1375 ohms

    If the I(ADJ) * R2 term is added, E =IR = .00005 * 1375 = 0.069 volts added to the 15.

    For 1.25 volts out, R2 would be 0.
    Last edited: Apr 28, 2011
  5. SgtWookie


    Jul 17, 2007
    The 1.25v (called Vref in the datasheet; measured from OUT to ADJ) is nominal; it might be anywhere from 1.2v to 1.3v and still be within specifications - but it's usually pretty close to 1.25v.

    In order to ensure that 10mA current flows from OUT to ADJ, a 120 Ohm resistor is typically used; as 1.2v/120 Ohms=10mA. If there is less than a 10mA load on the regulator output, the output voltage will likely be higher than expected.

    Iadj can vary as well; it's specified as between 50uA and 100uA. I've found that 70uA to 80uA is fairly typical.

    Note that you will not be able to output less than Vref, unless you have a negative reference for the low side of R2.

    Note also that for a given output current, as your output voltage decreases, the power dissipation in the regulator increases.

    Let's say you have a 1A load; and you have 19v in.
    With 15v out of the LM317, dissipation in the load is 15v*1A = 15 Watts; power dissipation in the regulator is (19v-15v)*1A = 4 Watts.
    With 2V out of the LM317, dissipation in the load is 2v*1A = 2 Watts; power dissipation in the regulator is (19v-2v)*1A = 17 Watts. You will need a LARGE heat sink to keep the regulator cool at low voltage outputs.
  6. Jaguarjoe

    Active Member

    Apr 7, 2010
    Considering that this power supply will most likely be made from standard parts, and as Sarge pointed out there is min/max for the chip's parameters, I came up with this:

    Vref=constant reference voltage between Vo and ADJ pins=1.2v
    Vo=output voltage=15v
    R1=resistor across Vref=unknown
    I1=current through R1=unknown
    Iadj= current out of ADJ pin=50ua
    R2= output adj pot or rheostat (1k is standard value)=1k
    V2=voltage across R2=unknown

    Vref = 1.2v= I1*R1

    VR2= 15-1.2=13.8v
    (13.8/1000)-0.00005= 0.01375=I1

    Vref= I1R1
    R1=~87 ohms

    82 ohms is the nearest standard value to use that will guarantee operation.
    Last edited: Apr 28, 2011
  7. k7elp60

    Distinguished Member

    Nov 4, 2008
    I use the basic formula R2= R1((Vout/1.25)-1)

    In simple terms divide the regulated voltage you desire by 1.25. Subtract 1 from that number. Then multiply by the value of R1.

    Example regulated voltage desired 6 volts R1= 120Ω. 6/1.25 = 4.8
    Subtract 1 from 4.8 4.8-1=3.8. Multiply 3.8 by 120 3.8X120=456
    So R2=456Ω The closest standard value is either 430 or 470Ω

    Regulated voltage=1.25((1)+(R2/R1)) In this case the output with a 430 resistor would be 430/120 +1 X 1.25 = 5.73 volts. With the 470Ω resistor
    470/120 +1 X1.25 =6.14 volts.
    As mentioned earlier the Iadj current can generally be ignored, and one can see that changing the value of R1 other than 120 will affect the output voltage. I chose R1=120 to ensure the minimum load current does not become less than 10mA. For the LM317 that is the minimum load current for stability.