Welcome to Solid State Guitar Amp Forum | DIY Guitar Amplifiers. Please login or sign up.

April 28, 2024, 10:33:29 PM

Login with username, password and session length

Recent Posts

 

simple limiter for chip amp

Started by illprincipe, January 20, 2015, 03:35:43 PM

Previous topic - Next topic

illprincipe

hi,

i'm thinking of building a hybrid amp, (tube preamp and lm386 poweramp), and whilst reading up on solid state / hybrid topology, one thing that often came up was a limiter to prevent the ss poweramp from clipping, which makes sense to me. The only circuit I found that was actually used in guitar amps was the VOX limiter (http://smg.photobucket.com/user/rickydon/media/voxtmixlmt.gif.html), which I find too complicated to implement for such a simple project.

1) does a limiter actually make sense for a simple lm386 chip amp, or am I overthinking this?

2) could I just use something simple like this: http://www.261.gr/limiters.html ?

3) apparently the STA540 (that is used in the orange microterror) has a built-in limiter - is someone aware of a chip more similar to the lm386 in terms of simplicity, footprint and that is proven and tested as guitar amp?

Does anyone have any other simple ideas? Or is it overkill anyway?


J M Fahey



Not much sense in a 1/2W  àmp !!!!  :o

Now if we were talking a 10/20W`one, that's something else.

illprincipe

OK, thought so... would you mind explaining me why, just out of curiosity? What difference does it make wether the amp is 1/2 or 20 watts? Isn't the limiter's purpose to improve the sound by preventing the chip from clipping?
Please bear in mind, I'm quite new to SS amp topology.

My decision on the LM386 isn't final btw, if you can point me to a ~10-20W amp that isn't much more elaborate (and runs with 12V), I might consider it.

Roly

#3
Compressors and limiters have occasionally been included in guitar amps, but they are very common in modern bass amps.

You have a simple choice - put in the circuit complexity to get the desired results, or go for a simpler circuit that doesn't give those results.  As the saying goes, "you can have it good, cheap, or quick, but you can't have it all three".  In reality you are lucky to get one out of three.


Quote from: illprincipe1) does a limiter actually make sense for a simple lm386 chip amp, or am I overthinking this?

No.  Yes.


2) Yes.


Quote from: illprincipewould you mind explaining me why, just out of curiosity? What difference does it make wether the amp is 1/2 or 20 watts? Isn't the limiter's purpose to improve the sound by preventing the chip from clipping?

In s.s. guitar amps generally output stage clipping is avoided because it has a particularly harsh sound.  There are differing opinions as to why this is, but little dispute that it's true.  Designers therefore try and make some stage in the preamp clip before the output stage, and in a manner that is more controlled, less abrupt, and often to enhance second harmonic generation.

In this context the primary difference between a 1/2W amp and a 20W amp is that the lower power amp will be driven much harder to get a reasonable Sound Pressure Level, and therefore will tend to clip far more often - lack of signal headroom.  A limiter on a 1/2W amp may improve the sound quality, but will restrict the sound quantity, typically by an unacceptable amount, leaving you with the choice of loud enough but nasty, or nice but too quiet.  Since a higher power amp will normally have much greater reserves you can get nice, and loud.


Quote from: illprincipeMy decision on the LM386 isn't final btw, if you can point me to a ~10-20W amp that isn't much more elaborate (and runs with 12V), I might consider it.

The amount of power obtainable from a power amp stage is determined by the supply voltage and the load impedance.  To get more power you can go for more supply voltage, or lower speaker impedance.  This is a particular problem in cars with 12V electrical systems, and why speakers with low impedances, e.g. 2 ohms, are often found in car systems.

One way to get around this is to use a "bridge" amp which doubles the available voltage by using two power stages to drive both ends of the speaker in opposition.

Speaker systems with impedances of less than 2 ohms tend to have a few problems, such as being lossy/inefficient, so for the amps in "doof cruisers" an inverter is used to raise the 12V vehicle supply to something more like +/-35V, allowing much higher power into more conventional speaker impedances.

So if you want 20 watts from a 12 volt supply you are effectively going to have to go with a bridge design, but circuit complexity is not just a linear function of output power, a 20 watt bridge amp isn't much different from bridging a pair of LM386's.

I'll leave it to others like JMF to suggest specific chip amps (since I don't use them much).

One of the key points about building your own gear is that you can try out "crazy" ideas, and you can change/rebuild ideas that don't work, and all for minimal cost, mainly just your time.  Nobody, not even highly experienced professional designers, turn out perfect designs first time, every time; almost all designs need to go through cycles of refinement.

You design stuff on paper, or these days in a simulator such as LTSpice.  Then, as engineers say, "you throw it up against the Universe and see what sticks" - build an actual prototype and see how it works.

Front end limiting can easily be obtained by making sure the preamp clips before the main amp.

HTH



(edit to add...)

Quote from: illprincipe3) apparently the STA540 ... has a built-in limiter

No it doesn't.  I don't know where you got that idea, but it certainly wasn't from the ST datasheet.  It has a thermal limiter, but that's a different thing entirely from a signal limiter or compressor.
If you say theory and practice don't agree you haven't applied enough theory.

illprincipe

#4
Thanks for your expansive answer. I got the idea that the STA540 has a limiter from someone who posted just that in the orange microterror thread over at fsb - and the datasheet says under 6.7.3. Clipping detection: "Current sinking at pin 10 occurs when a certain distortion level is reached at each output. This function initiates a gain-compression facility whenever the amplifier is overdriven." I had no idea what that meant and just interpreted this as the limiter mentioned by the fsb-member...

But seeing as the micro-terror has no limiter then and sounds actually quite good (at least according to youtube videos) - I'll probably won't need one for my project as well.

However, should there be a relatively simple way to implement a limiter with, say, a tda7240 I'd love to try it just out of curiosity. I don't want to build a limiter that has more parts then the rest of the amp though...

Edit: I renamed the topic to so it's no longer limited to the lm386

J M Fahey

Quote from: illprincipe on January 20, 2015, 06:13:59 PM
OK, thought so... would you mind explaining me why, just out of curiosity? What difference does it make wether the amp is 1/2 or 20 watts? Isn't the limiter's purpose to improve the sound by preventing the chip from clipping?
Please bear in mind, I'm quite new to SS amp topology.

My decision on the LM386 isn't final btw, if you can point me to a ~10-20W amp that isn't much more elaborate (and runs with 12V), I might consider it.
Yes, of course :)

1/2W is such a low power, that it will practically be clipping all day long.
And difference between diode preclipping (what you call limiter) and straight rail to rail clipping is real but somewhat subtle, lost on such a weak amp.

The real purpose in VOX amps was simply not stated, and not really to "improve sound" .

Fact is, those very old amps had lots of problems, a big one was that when clipping, a transistor "stuck to the rail" , also calleed "latch up" and didn't turn off when it should, so for (many)  microseconds it was passing high current and supporting high voltage at the same time, a deadly combination.

Problem is, of course, that old transistors were "slow".

Old designers didn't know what was happening, only that clipping SS power amps way overheated when clipping (theory says they should cool off in such condition) so they added pre-clipping so actual power amp didn't do it.

But since about 1970 that is not needed any more ;)  .

Simple 10/20W 12V amplifiers:

1) Craig Anderton's "8W practice amplifier" which can actually deliver 10W into 2 ohms .

It does not give you definitive resistor values but an acceptable range, you can vary them between those limits to go from a plain power amp, driven by a preamp (or pedal or pedalboard) to a higher sensitivity simpler one which can be driven straight from the guitar, and use the guitar's built in volume and tone controls (similar to what the simplest LM386 amp does).

2) in fact it's not much more than the plain datasheet application for TDA2003 chipamp, only with some resistor values/gain tweaked.

Looking carefull you'll notice it's the same thing, drawn in a different order ... and Craig Anderton's values apply.

Here they show 18V supply ... because it stands up to that voltage safely.

In fact, a standard cheap 12V 1A (up to 2A) transformer plus a diode bridge and a 4700uF x 25V capacitor will give you very usable 16V DC for peanuts, which will also feed your preamp or can easily be lowered to 9V or 12V as needed by it.

3) for around 20W, here's Pignose HOG 20 , using a relatively simple bridged chipamp :
(attached at end of Post)

Only problem, they made a schematic mistake, the correct one is this, straight from the datasheet.
As you see, it's not way too complex:


That said, please do start with the LM386 amp, you must start with something and "practice makes perfect" .

Don't try to start with "the amp which you will use forever" because it does not work that way :)

Make your favorite preamp (or even also start with a simpler one) , couple it to thye LM386 ... later build a single TDA2003 one ... then a 15/20W bridged one .... then a 50W LM3886 one .... the Sky is the limit .

I started making a 2 or 3 transistor, car radio type one, in 1968 ... by 1972 was designing and making 200W RMS amps, by 1975 500W ones .... still make them today, over 40 years later  :duh

Go step by step .... and this is FUN :)

Roly

What par 6.7.3 doesn't make clear, but is implied in 6.8 Fig 28, is that pin 10 provides a control output to an external compressor/gain control that YOU provide.

Under "6.8 Handling the diagnostic information"
"... an interface circuit based on the one shown in Figure 28 could differentiate the information and flag the appropriate circuits."

If you look at 1.1 Fig 1 Block Diagramme you will see the four signals go straight in, and no gain control is provided on-chip.

Par 6.7.3 should read;
"This function can initiate an external gain-compression facility whenever the amplifier is overdriven."

It took me a while to decode "fsb" to freestompboxes.org.

Well it sure ain't "Class-D"; and from the same font of wisdom, Davelectro, "It has a built-in soft limiter".  Sorry Dave, wrong on both counts.

The Orange Micro Terror build may make such use of the clip signal out of pin 10, but the chip amp itself sure don't.  {If it did there would be a whole lot of detail in the chip data sheet about the "soft limiting" threshold and compression law, and would be touted as a major feature.}


The most utterly braindead compressor/limiter is a globe driven from the output shining on an LDR across the signal path somewhere, like this.
If you say theory and practice don't agree you haven't applied enough theory.

illprincipe

First of all, thanks.

Roly, I do apologize for my "code", I figured the diy-guitar-electronics-community was small enough for it to be obvious.

I've decided I'm way out of my depth here - so one more long-shot and then I'll do as J.M. Fahey suggested - preamp first, then lm386, then something bigger :D - the longshot being this circuit: http://www.electroschematics.com/138/dynamic-compressor-passive-components-no-power-supply/

Would it be worth to try this between (a tube-)preamp and (a tda7240a) poweramp? Not looking for some holy grail tone here, I just find the concept of limiter + ss-poweramp interesting...

J M Fahey

It's interesting and somewhat similar to some of phatt's experiments, which he fine tuned to get very good sound in his system.

I think you will have to tweak it a lot to adapt it to your preamp/power amp combination.

But there's a simpler way  :o

Basically:

1) you overdrive your tube preamp.
By definition, output signal won't go beyond a certain level, no matter what.

2) you strongly attenuate its signal output (which can easily be , say, 60V RMS) so you just get a little more than needed to drive your SS amp.

Say, you attenuate it with 47k in series with a 1 k screwdriver adjustable trimmer ... which you set to 0  :o

3) you scope the SS amp output (which is still silent) and s-l-o-o-o-o-w-l-y-y-y rise volume using the trimmer.

You will start with the exact same waveform that the overdriven tube preamp is making, of course, the SS amp is transparent and clean.

4) at some moment, you will see that the Tube preamp waveform starts being clipped top, bottom, or both, by the SS amp.
Then you back up a little, until you recover the Tube waveform.

Bingo: you play as you wish with your yube preamp, the speaker will receive a faithful copy of that .

The speaker does not know who or what is driving it, will just reproduce that waveform.

So as you see, no real need for an added limiter or compressor, just accurate level matching.

That's why I suggest a screwdriver adjustable trimmer and not a standard pot with a knob: you set it once, then leave it there forever.

Davelectro

Quote from: Roly on January 22, 2015, 03:28:24 AM

Well it sure ain't "Class-D"; and from the same font of wisdom, Davelectro, "It has a built-in soft limiter".  Sorry Dave, wrong on both counts.

OK.

Back then no one knew for sure what was going on inside the microterror. It was rumored to be class D because of its small size.  So I guess I got carried away by those rumors. Gut shots revealing the (now obvious) TDA started to show up later.

I misunderstood what the datasheet says about the gain compression feature. I'm sorry.

teemuk

#10
"Limiter" can practically mean two things.

You have limiting by clipping, which is basically about instantenous gain compression that is so drastic that it seems to "clip" away all signal peaks at some predetermined threshold.

Or you have limiting by gain compression, where amount of gain is controlled by external signal. This is typically not instantenous limiting, the driving signal always tends to introduce some attack and decay characteristics. Also, it's more about dropping the overall gain in magnitude that prevents traditional signal clipping.

In nutshell, clipping limiting limits by clipping off signal peaks. Feed sine wave to it and it clips off top portions of the wave and introduces significant amount of quite audible distortion. Clipping action can be either soft or hard, but in practice the difference is very, very subtle.

Externally driven limiter limits by reducing gain. Feed a sine wave to it and the output signal basically just has gradually decaying magnitude but overall retains the sinusoidal shape, which means much less audible distortion. This type of limiting tends to portray clipping distortion only at very first signal peaks, at which the "detector" circuit, driving the limiter stage, is too slow to instanteniously react.

So which one is it?

Yes, they will BOTH reduce headroom because they work by lowering overall signal magnitude. Both are clearly audible but in different manner: Clipping limiter in operation pretty much just sounds like clipping distortion, gain compressing limiter makes the overall sound quieter. If not implemented properly, it makes the amp too quiet, or the volume pumps up and down annoyingly.

Quoteapparently the STA540 (that is used in the orange microterror) has a built-in limiter...
QuoteThe Orange Micro Terror build may make such use of the clip signal out of pin 10, but the chip amp itself sure don't. 

Pretty much this. The datasheet makes no remarks of other features but the "dignostics" terminal, which indicates both clipping, overcurrent, over temperature and standby and requires some additional circuitry to determine when the signal is actually clipping instead of other alternatives that also toggle the flag.

Secondly, when chips and such do feature "soft clipping" it may simply refer to decent behaviour during overdrive. The signal may hard clip but it doesn't "stick to rail", portray hysteresis, etc. which are effects that result into really nasty type of clipping distortion. As said, the audible difference between traditional soft and hard clipping is extremely subtle.

illprincipe

OK, thanks again to everyone who participated.

Again, the limiter topology is way beyond my electronics knowledge to figure out a circuit myself, but hey, I've at least learnt a lot about limiters in this thread  :)

JM Fahey: that preamp attenuation / level matching thing sounds interesting. I might get back to you on that once I'm actually building the amp.