I have built a power supply using an LM317:


simulate this circuit – Schematic created using CircuitLab

When the supply is on for a rather long time (several hours) with a respectable load, the output voltage increases in the order of several hundreds of millivolts. I think this is because of the warming up of the LM317. I already have a heatsink, but the IC is still getting hot, especially with a great load and a long on time, of course.

I was wondering if there would be any way to make some kind of protection to make sure the voltage doesn't change too much. I've thought of these options:

  • Adding a PIC on a separate 5V supply which monitors the supply and beeps when it changes too much. This might be an overkill for such an easy problem.
  • Adding a PIC and make R2 a digital pot, so that I can digitally set the output voltage, and the PIC takes care of the rest and automatically changes the resistance on the adjust pin when the output voltage changes. Again, an overkill, and I don't want to have a lot of work for this.
  • Something with a comparator, but that gives a problem with that the supply is variable. I'm not sure how I could work this out with a comparator...
  • Bigger heatsink, better placement, adding a fan - would probably work indeed, but I feel like there should be an electrical solution (i.e. with adding a circuit) and I'd like to see that solution.

So, what would such a solution with a circuit look like?

Here are two photos of my setup:

enter image description here enter image description here

First, on the right: the heatsink with the LM317
First, on the left: the board with R2 somewhere
Second, bottom: the two pots (5K and 500) that are R1 together

  • \$\begingroup\$ What is the current draw? Are you exceeding the rating? \$\endgroup\$ – Scott Seidman Apr 14 '13 at 12:17
  • \$\begingroup\$ @ScottSeidman 100mA, the LM317 is rated for 1 or 1.5A, I believe. \$\endgroup\$ – user17592 Apr 14 '13 at 12:19
  • \$\begingroup\$ You should bypass R2 with a capacitor to improve transient response. See the datasheet. \$\endgroup\$ – user207421 Apr 14 '13 at 12:33
  • 1
    \$\begingroup\$ Are R1 and R2 mounted in a way that they also heat up together with the LM317? \$\endgroup\$ – AndreKR Apr 14 '13 at 12:33
  • 1
    \$\begingroup\$ To people who voted to close as duplicate, the question Anindo linked has a circuit where output drifts down over time. This question has output drifting up. This suggests a different root cause of the drift, and not a duplicate question. \$\endgroup\$ – The Photon Apr 14 '13 at 16:00

This answer is a bit speculative, but its my best guess what's going on.

To get 5 V output, you have your pot turned to get about 720 ohms for "R2". It's got (5-1.25 =) 3.75 V across it, so it's burning about 20 mW. Even though you don't feel it to the touch, it is heating up inside. A pot is probably a relatively large part, which helps explain the very large time constant you're seeing on this voltage drift. Check the datasheet to see if the pot has a postive tempco, or hit it with a hot air gun and watch the output as a first step to confirm or reject this as the source of error.

Another slightly less likely effect, also involving the potentiometer, would be if thermal effects are causing the wiper resistance to drift, or if a chemical change (like oxidation) is happening at the contact of the wiper to the resistive element over time. Since the wiper is part of the "R2" controlling your output voltage, any effect on the wiper resistance will also cause your output to drift.

Depending what kind of pot you're using, and if you really need adjustability, you could try changing to a higher quality pot with lower tempco and known wiper resistance stability, or switching to a fixed resistor, and see if the drift is reduced or eliminated.

  • \$\begingroup\$ Oooh, I like the hot air gun as a debugging tool! \$\endgroup\$ – angelatlarge Apr 14 '13 at 16:10
  • \$\begingroup\$ A soldering iron would be a better tool. You can touch individual components to see what, and if, causes the biggest difference. \$\endgroup\$ – Szymon Bęczkowski Apr 14 '13 at 16:23

From the image above, the heatsink maybe inadequate for your load. Solution:

  1. Use a bigger heatsink. Produced heat is directly proportional to the Input voltage and from the load of the regulator.

  2. Check the input voltage. An input of 9V for 5V output is OK.

For a great load, boost the output of the LM317 with additional power transistors with heatsink. The number(NPN transistor) depends on how high the current output rating of your transformer.

  • \$\begingroup\$ To prevent or minimize heat on LM317, another suggestion would be to boost the output of the LM317 with NPN power transistor. \$\endgroup\$ – Rommel Feb 1 '15 at 8:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy