LM386 circuit pulling 450mA and getting hot! What have I done wrong? - Page 1
Forum section: electronics / beginners

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 04:47:34 am
content: Hey allWhat was meant to be a really quick and easy Friday night project has turned into an absolute mission!I was building a little LM386 audio amp using the circuit below (next to my little piece of poo) and connected it to my power supply to find it is pulling ~0.5A at 12V and the IC is getting super hot (like hitting 70C which is the data sheet max within 10 seconds kinda hot!) so am guessing it is somehow shorting through the chip?I have compared my circuit to the schematic probably 50 times and can not seem to see anything wrong. I’ve checked the solder tracks for shorts / cleaned between them and all seems fine. I did continuity tests and they all were as expected.I even tried connecting the circuit with the chip removed and tried connecting power and ground to the IC but both seemed normal. I even started poking at the IC holder but other than the obvious (power goes to power, ground goes to ground etc.) I wasn’t sure what I the measurements I was getting were sayingMaybe I just need a fresh set of eyes on it on it but any ideas where I have gone wrong / best places to start looking?

author: magic
author_rank: Super Contributor
timestamp: October 07, 2023, 05:30:56 am
content: According to your schematic, all pins other than power supplies have capacitors in series with them, so if there is high DC current flowing through the chip, it has to be pin 6 to pin 4. (Or vice-versa, are sure you didn't reverse supply polarity?)This is weird, because you said that it doesn't overheat if you simply connect 12V to bare chip? Maybe it's oscillating, not sure how much power it can pull under such conditions. Do you have access to any scope?Also, this chip looks weird to me. I would say it looks like TI or JRC, but I'm not sure if either of them ever made LM386. Where did you buy it, does the top of the package look like it has been sanded? If this is something other than LM386 with fake markings, you may spend an eternity trying to fix your ciruit...

author: iMo
author_rank: Super Contributor
timestamp: October 07, 2023, 06:22:53 am
content: There are 2 kinds of LM386 for different max voltages, AFAIK.Doublecheck your capacitor's values - ie 4n7 vs 47nF in series with the 10ohm.Also - there seems to be a short near the switch (two wires Vcc vs. Gnd).

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 06:32:44 am
content: Quote from: magic on October 07, 2023, 05:30:56 amThanks so much for the reply!I’m pretty sure pins 4 and 6 are good. Pin 6 connects directly to the centre power “strip” (red line in the centre which connects directly to the switch) and pin 4 goes directly to ground. Apologies a couple of wires go under capacitors such as the one for pin 4 and the one for pin 7 so looks super messy (it really was meant to be a quick and easy project so just used a scrap bit of strip board and made it fit)!Additionally, adding power makes the LED work so assume I would have popped that if I had it all backwardsI have drawn a “wire path” version to hopefully make following it a little easier below. If a line stops on a component, it is connected to that. If it goes straight through, there is a wire underneathYeah, connecting the bare IC up to power and ground (pins 4 and 6) seems to not cause an issue! It just pulls ~6mA and doesn’t get warm at all!I do have a little single channel hand held scope! What do you recommend I should I probe with it?As for the IC’s themselves, they came from Digikey and the other ones I have have much clearer markings. I think I have just literally cooked the markings of this oneI can pop another IC in there but figured I’d just see if anyone can see an issue with my circuit before possibly sacrificing another chip to the electronics godsEdit: here is the link to the exact IC’s I orderedhttps://www.digikey.com.au/en/products/detail/texas-instruments/LM386N-3-NOPB/148191

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 07:04:56 am
content: Quote from: iMo on October 07, 2023, 06:22:53 amAh damn! I did make that mistakeHad a 4.7nf cap instead of a 47nf cap! Thank youThat said, I’ve replaced that and am getting the same thing still.Is it likely I have just killed this IC from that and that is what is causing the issue or is there more likely still another issue?I don’t think the 2 crossing wires by the LED / switch are and issue as both are VCC so should be fine yeah (also they are a good 3mm away from each other vertically so shouldn’t be shorting anyways)?

author: iMo
author_rank: Super Contributor
timestamp: October 07, 2023, 07:40:36 am
content: Wire up say 10-33ohm resistor instead of the speaker and hook up the oscope probe on it.Watch the output with the various positions of your potentiometer (do not use any input signal, no wire on the input). You should not see any signal except of couple of mV noise (best done with a battery powered amplifier).Also try to disconnect the RC between the pins 1 and 8 (to lower down the amplifier's gain).The RC between the pins 1 and 8 sets the amplifier's gain between 20 (none RC there) and up to approx 200 (with the 22uF cap and none resistor there).With larger gains it can oscillate (because of your wiring parasitics and/or a not sufficient decoupling). The LM386 amp is pretty prone to oscillation with gains set >20 from my experience..Your decoupling 47uF between Vcc and GND seems to be rather low value, try something like 220uF-1000uF/16V with say 100nF ceramic (as close to the chip as possible) in parallel there.Sometimes it helps to put a 10-33ohm resistor from the Vcc into the pin 6 of the 386 (and the decoupling capacitors from the pin 6 into the GND)..Do use "star ground" style wiring for GND related wires (all "component's grounds" wired into a single point/joint).Doublecheck the polarity of all your elyte capacitors as well..

author: magic
author_rank: Super Contributor
timestamp: October 07, 2023, 09:03:44 am
content: That wrong capacitor is important for stability, theoretically it may have caused the amp to oscillate and overheat.Half amp from 12V is 6 watts, which is a lot for DIP8 (typically less than 1W maximum rating). This chip may be cooked to death by now.

author: iMo
author_rank: Super Contributor
timestamp: October 07, 2023, 09:34:39 am
content: Try to start with the lowest gain of 20 (none RC between pin 1 and 8, see my schematics above), I would also increase the 47nF (in series with the 10ohm there) to 100nF (for stability).I would also go with the 33ohm (it could be even a higher value like 56ohm) in the VCC and the decoupling as in my schematics.When all goes fine you may start to experiment with higher gains (the 22uF with the series resistor - by changing the resistor's value you'll change the gain, the higher the resistor's value the lower the gain).

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 10:19:37 am
content: Thanks allI hooked up a big 10resistor and got nothing on the scope but some very minor noise that didn’t change at all when adjusting the trimpot.I disconnected the 22uf cap between pins 1 and 8 and no change.I also tried 6V rather than 12 but it was still pulling a comparable current (I think it was about ~250mA)!Interestingly, I’ve found that if I have the stip pads of(on the bottom) sitting on my finger when I turn it on, the current sits at about 50mAAs soon as I shift my finger it jumps way up and won’t go down if I touch the pads again (can power it of and on again and it is repeatable though). I think I’m touching the pads for pins 1,2 and 3 when this happens but not 100% as my finger usually covers like an eighth of the boardI tried resoldering everything / pushing everything through further to ensure a good connection as thought this must be the sign of a poor connection but doesn’t seem to have done anything.Will probably just pull it apart peice by piece at some part to see if I can find out exactly what is causing it or just start over if I still can’t work it outThanks so much for the help regardless all and will let you know if I do work out what is going on in the autopsy

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 11:26:19 am
content: I think I’ve made some progress!I disconnected the 10resistor and current instantly drops to a nice stable 12mA!Got all excited and grabbed a new IC to test hoping that it was the IC causing the issue but, nope, as soon as I touched the resistor to ground current maxed out (had it limited to 50mA as didn’t want to kill it but instantly hit that)Now, as far as I know that resistor and cap combo are meant to be there (it is in the data sheet test example with basically the same values 0.05 and 10vs 0.047 and 10).Any ideas why the chip is absolutely pupming current through there at idle?Edit: for those playing at home, the 10resistor is the purple line in the picture added previouslyAlso, although I think it is extremely unlikely, I noticed Digikey doesn’t have any LM386’s in stock. That seemed a little weird to me as it is such a common IC. Is it possible there was a bad batch and that is why they are showing 0 in stock?

author: wasedadoc
author_rank: Super Contributor
timestamp: October 07, 2023, 11:54:47 am
content: Your capacitor from pin 6 to pin 4 has quite a long path on both legs.

author: Ground_Loop
author_rank: Frequent Contributor
timestamp: October 07, 2023, 12:08:25 pm
content: As above, you don't have a DC path anywhere. I think I would try removing that 100n cap and tying pin 2 directly to ground.

author: Dan123456
author_rank: Regular Contributor
timestamp: October 07, 2023, 12:15:37 pm
content: Oh my god… please ignore this whole threadI am just an absolute fucking numb nutsTurns out, this whole time I had just forgotten to remove the material from the strip under that 47nf cap so was just shorting the output to ground the whole timeThis is exactly why I usually use perfboard and not strip boardI am so, so sorry for wasting all your time but really, really appreciate you all trying to help my stupid ass

author: alligatorblues
author_rank: Regular Contributor
timestamp: October 09, 2023, 01:21:03 am
content: The IC might be reversed in the socket.

author: BillyO
author_rank: Super Contributor
timestamp: October 09, 2023, 02:11:15 am
content: Quote from: alligatorblues on October 09, 2023, 01:21:03 amIf you look at the OP's latest comment (the one before yours) you'll see the problem was resolved.I plugged one of these in around backwards once, but if I recall correctly it did not survive. Lucky they are cheap.

author: nigelwright7557
author_rank: Frequent Contributor
timestamp: October 09, 2023, 03:16:40 am
content: In 1980 I went on a City and Guilds electronics course.In the morning we did theory and in the afternoon built up circuits in relation to the theory.One of the projects was a LM386 amp.About half the class had trouble with red hot LM386 and the other half didnt.The tutor put it down to layout differences.In more recent years I have worked with other chip amps and they are also touchy about layout especially the feedback path which needs to be short.1mm of track/wire is 1nh of inductance.Also, some have a minimum gain before oscillating.While these chip amps are good in theory they can be a minefield for newbies.Anyway, pleased you got it sorted.

author: BillyO
author_rank: Super Contributor
timestamp: October 09, 2023, 03:41:32 am
content: Quote from: nigelwright7557 on October 09, 2023, 03:16:40 amIs this like one of those "fuzzy-wuzzy wazzent very fuzzy, wazzhe?" rules of thumb?