OpAmp Audio

 

      Operational Amplifiers (Op-Amp) were originally developed to build Analog Computers (and many Computer systems used in Aircraft still use them for this purpose). They are pre-built amplifier modules that are general enough to be plugged in almost anywhere an amplifier is needed. The advantage is that a small Op-Amp can often replace 20 or more discreet components. For people who like to build effects, mixers or other custom audio gear, they are a quick way to put together a highly functional amplifier stage.I won't spend much time on theory, I would rather tell you generally how they work and how you might use them in your projects.
      NOTE: This series of articles are aimed at teaching musicians how to use Op-Amps. It leaves out things that I consider un-important for this specific topic. The goal is to keep things simple and to the point.
      The basic diagram for an Op-Amp is shown in Figure 1. I've left off the power supply connections for this disccusion, however there is always a Positive and a Negative power supply requirement for these devices. Its possible to find Op-Amps packaged 4 to a 14 pin integrated circuit, as well as dual and single Op-Amp packages. To keep it simple, we will talk about an individual Op-Amp.
      There are many types of Op-Amps. The ones that we will discuss are the common voltage amplifier type, such as a '741', 'TL081' or 'TL082' that are packaged as 8 pin integrated circuits. You'll note that there are 2 inputs - an Inverting Input (marked with a - sign) and a Non-Inverting Input. There is a single output. How it works internally is not really important for this discussion.
      Most analog applications use an Op-Amp that has some amount of negative feedback. The Negative feedback is used to tell the Op-Amp how much to amplify a signal. In Figure 2, this Op-Amp will not amplify at all, it operates at Unity Gain, also known as a gain of 1. Unity Gain arrangements are also called Voltage Followers (See Figure 10) since they track the input voltage at the exact same level at output. Sometimes, you will want an output that is Inverting, and sometimes you want one that is Non-Inverting - often, you don't really care which way it works as long as it provides-an output signal.

       
      If you apply an input to either the - (Inverting) or the + (Non-Inverting) input, the Op-Amps output basically maintains the input level, but in the case of applying an input to the Inverting (-) input - Figure 3, the output signal will be 180 degrees out of phase with the input. In Figure 4, you see that the signal comes thru unchanged.
      This may not seem very exciting, but the output current of the Op-Amp is often substantially higher than that of the Input device. In a case where you need to have a single guitar connected up to 3 or 4 stomp box inputs, the guitar pickup output often doesn't have enough current (guitar pickups don't generate very much power) to drive things without altering the tonal qualities of the instrument. Adding a Voltage Follower will allow the input signal to be sent to many stomp boxes with degrading it. Some times, you simply need to flip a signal around so that its 180 degrees out of phase with the input - you can't do it much simpler than this.
      If an Op-Amp is an amplifier, how hard is it to get it to amplify the signal? Its very easy. The following 2 schematics show the 2 variations again, this time configured to amplify the signal.

       
      For the Inverting Op-Amp (Figure 6), the way that you define the gain is by setting the ratio of R1 to R2. Neither of these resistors will ever have much power going thru them, so these can be very tiny - often 1/4 or 1/8 watt resistors are used. To keep power consumption down, as well as noise introduced by cheap carbon resistors, we will use resistors in a range of 10,000 Ohms thru 1 Meg Ohm.
      If R2 is equal to R1, then we have Unity Gain, or a 1X Amplifier - This is a 1:1 ratio. if R2 is twice the resistance of R1, we have an Amplifier with a gain of 2 - a 2:1 ratio. To build the 2X gain amplifier, lets pick resistor values that will set the 2:1 ratio - R2 = 20,000 ohms and R1 = 10,000 ohms (20000:10000 = 2:1). That really wasn't that hard to do.
      For the Non-Inverting amplifier (Figure 7), the gain is the ratio + 1, so a 1:1 ratio is really a gain of 2. Otherwise, everything else remains the same.
      Figure 7 shows the results of a 2X gain Non-Inverting amplifier stage. To make it a gain of 10X, set the ratio to 9:1. That would equate to R2 = 90,000 ohms and R1 = 10,000 ohms. To make it gain of 100:1 (99:1 + 1), set R2 = 990,000 (990K) ohms and R1 = 10,000 ohms. This is probably simpler than you thought.
      Its easier to design for the Inverting Op-Amp - the ratio is the gain, is 100:1 - R2 - 1 meg ohms and R1 = 10,000 ohms. The side effect is that the inverted output signal is 180 degrees out of phase with the input signal.
      One side effect of high gains is that sometimes the Op-Amp is not fast enough to keep up with the voltage swings. There is a parameter called Slew Rate that defines how fast an Op-Amp is. A common '741' Op-Amp is pretty slow with a 1/2 volt per micro-second Slew Rate. This is fine for Voltage Followers, but if you push a 10X gain thru a '741' Op-Amp, you'll find that it can alter the tonal quality of your signal, usually attenuating the high frequency parts. There are much faster Op-Amps available, and such as the TL081 which is 13 volts per microsecond - which is plenty fast for anything up to a 100X gain. A TL081 is available for around $1.00 (US) at Radio Shack. A TL082 is 2 TL081s in an 8 pin integrated circuit, usually at the same price as a TL082.Op-Amps do become a load on the input signal. If you want the lowest possible loading effect, you would use a Non-Inverting Input - typically, the impedance is 1 meg ohm or more. An Inverting amplifier has the loading effects of the resistors (which is why my examples use values no lower than 10,000 ohms - this is usually high enough to avoid any problems) - effectively the load will appear to be the same as R1. This could provide a substantial change in the tonality of the signal, if its very low level to begin with, which is why many input stages use a Non-Inverting voltage follower (Figure 10).
      If you wanted to make the gain adjustable, its only a matter of providing a way to alter the ratio of R2 to R1. Use a Potentiometer (variable resistor). Always wire it up with the wiper arm connected to one side of the Potentiometer in case that the wiper arm ever fails to make contact (this will prevent the feedback loop from ever being able to open up).Figure 8 shows the schematic. To give yourself a range of 0 Gain to 10X gain, use a 100,000 ohm Potentiometer (use liner taper if possible) for R2, and 10,000 ohms for R1.
      Using an Inverting Amplifier, you can extend the number of inputs and create a mixer. Figure 9 shows the schematic. The ratio method remains the same. To get a mixer with a 10X gain, the relationship between R2 and R1-A defines its gain. This applies to all the other inputs as well. You will want to maintain a 10:1 ratio between the R2 value and each individual R1 value. In this case for a 10X gain, R1-A, R1-B, R1-C and R1-D are all 10,000 ohms. R2 is 100,000 ohms. Please note that you will need a few other components to allow you to connect this sort of mixer into your real world audio systems. I'll cover that interface in Part 2.
      You'll find that this sort of mixer works quite well up to approximately 8 inputs.
      Op-Amps can be used for many things that are non-audio - you can even build a digital computer out of them (it would take quite a few), using them as on/off switches. If you neglect to provide the Negative feedback, you will turn it into a switch instead of an Amplifier. Make sure that you use Op-Amps that are for the type of function that you desire, otherwise, you may choose one that operates in a non-linear manner (ie. its not for the types of applications shown here).


      The Simplest Op-Amp Stage used in Audio
    Please be aware that this discussion is aimed at the Pro-Audio area, and is not intended for Audiophiles or other areas of circuit design outside of the Pro-Audio environment. The concepts are generally the same, if not identical. However the topic area is vast and the intent of this discussion is quick and effective practical usage - not theory, advanced or extremely high end systems.

    Using your Op-Amp Circuit in the real world

    Almost all active (semi-conductor or tube based) audio units add some degree of DC voltage bias. What this means is that the audio signal can have positive or negative voltage bias - this is something that can cause large distortion errors, or other problems as you stack modules together. The easiest way to fix this is to assume that you will encounter the problem and use a blocking capacitor at the input and output to eliminate the DC offset.A capacitor is used in this context to pass only the AC (Complex Waveform) component of the signal. As many of you might know, capacitors are also used in Cross-Over networks, as well as voltage storage in a power supply (to even out the voltage levels). For our use - which are circuits for audio signals at levels that are used in Microphones, Guitars, Keyboards and other electronic musical gear - there are some values that tend to work quite well. All the designs in this series will use those values for the types of input and output stages that you would use in this environment. Yes, it is possible to optimize this area, however, for our purposes, the values that I use will do an excellent job.
    One question that comes up frequently is how to pick the correct voltage part when choosing a capacitor - its quite simple - choose a part that is as high or higher rated than the power supply. If you are using 2 9 volt batteries to drive the circuit - thats 18 volts - you'll probably use 25 volt or higher capacitors. Never use a capacitor rated at less than the maximum voltage of the power supply. I frequently use 50 volt or 100 volt capacitors - they are often the same price and will give the same results. Don't skimp here.
    One problem that you will encounter with the input stages that are Non-Inverting is that the input stage needs a ground reference. Since the capacitor won't pass the DC equivalent of ground thru the capacitor, we need to add a fairly high resistance resistor that provides the ground reference for us. We don't need this on Inverting input stages because the Non-Inverting input is tied to ground and the Inverting input accomplishes the same thing by use of negative feedback. All the circuits shown here have these components in place along with the values.
    In Figure 1, you see a standard Inverting Amplifier. the gain is set by the ratio of resistors R2:R1 (As covered in Part One of this discussion). For example, to set it for a 10 times gain, R1 = 10,000 ohms and R2 = 100,000 ohms. This gives you 100,000:10,000 - or 10:1. Cin and Cout are the blocking capacitors. We only need to provide this blocking facility on stages that connect to other devices that are not part of our circuit, so, you normally only use Cin at your inputs, and Cout at your outputs - you don't need that many capacitors to resolve the DC offset problem. You'll note that there is anRout on the output stage. This is to provide a ground reference for the next active device that this circuit is plugged into.
    In Figure 2, you see a standard Non-Inverting Amplifier. The circuit looks pretty similar, except that there is an extra component in the Input DC Blocking section - its the ground reference resistor. You'll also note that the values of Cin differ depending on whether you are building an Inverting or Non-Inverting input stage. These values have to do with the input impedance differences. The output DC Blocking components are the same in either type of amplifier.
    You'll note one additional component - that is the shorting input jack that I show for the Signal In connection. This type of jack is wired such that when no 1/4 inch phone jack is plugged in, the input is set specifically to signal ground. Doing this eliminates a lot of potential noise problems.
    In Figure 3 we take the 4 channel Mixer from Part 1 and add the components needed to interface this with the outside world. The inputs are designed for high impedance devices, such as Guitars, Keyboards, High Impedance Dynamic Microphones and the like, that use single sided (unbalanced) inputs. You'll also notice that I've added a level control on each input to the mixer, otherwise, the DC blocking section is pretty much the same as the Figure 1 above.

    Balanced Low Impedance Outputs and Inputs

    You will need to interface to more than single sided inputs. Almost all of my microphones are Low Impedance and use XLR connectors that have balanced signals. I also often need to convert one type to the other depending on the Mixer that I'm using or the length of cable is exceptionally long. The following 2 circuits provide conversion from one to the other.
    Note: These circuits work best with a High Slew Rate Op-Amp, such as the TL081 or TL082.
    A good advanced reference book for this topic would be the "IC Op-Amp Cook Book" by Walter G. Jung (ISBN 0-672-20969-1 for older book that I have - current ISBN 0138896011). I got my copy in the late 1970's - there is a newer version available, however, the concepts remain the same.

      Please be aware that this discussion is aimed at the Pro-Audio area, and is not intended for Audiophiles or other areas of circuit design outside of the Pro-Audio environment. The concepts are generally the same, if not identical. However the topic area is vast and the intent of this discussion is quick and effective practical usage - not theory, advanced or extremely high end systems.

      Powering your Op-Amp Circuit with Batteries

      Batteries have the benefit that they are pure voltage and are not converted from AC (Alternating Current) - this eliminates the potential of adding noise in the form of 50 hZ or 60 hZ from your AC line. Batteries also allow you to move away from other power sources. This can be handy if you create something thats built into an instrument, or needs to be carried along as part of a wireless rig. If you are making outdoor videos, this could prove very handy. The downside is that batteries have a limited lifetime, and their power often drops off to unusable levels just when you need them most.Op-Amp circuits can be designed using low power chips that greatly improve the life of batteries. Choosing larger resistor values when you work out ratios for gains can also reduce current flow. Its hard to know which is the best choice without building it first, and sometimes you find that the power requirements are higher than you want. You can always use rechargable batteries (NiCad and NiMh cost a lot more, but they can be recharged hundreds of times).
      You really need at least 6 volts (+ 3 Volts and - 3 volts) to use an Op-Amp at all. If using 1 1/2 volt Alkaline batteries, this would equate to 2 batteries for the + supply and 2 batteries for the - supply. You could also use a single 9 volt battery, with a simple voltage divider to simulate + 4.5 volts and - 4.5 volts. For battery only power supplies, I prefer two 9 volt batteries, because it gives the circuit more potential life as the batteries start going dead.
      4 - 1.5 V Batteries 1 - 9 V Battery 2 - 9 V Batteries
      The multi-battery solutions require a DPST (Double Pole, Single Throw) switch to disable the batteries when not in use. This is more expensive and in general more trouble than many people want. Later, if you decide to use a battery eliminator (AC Power), you'll need 2 battery eliminators.
      In general, you'll usually find something like 1 Battery Power Supply the most commonly used method with battery powered equipment. With it, you can easily build in a battery eliminator jack.
      Battery Eliminator Version Battery Eliminator Plug/Jack
      You can use any 8 to 12 volt battery eliminator that is wired as the 'Note' shown in the above drawing (Center tap = +, Outside = -).
    Please be aware that this discussion is aimed at the Pro-Audio area, and is not intended for Audiophiles or other areas of circuit design outside of the Pro-Audio environment. The concepts are generally the same, if not identical. However the topic area is vast and the intent of this discussion is quick and effective practical usage - not theory, advanced or extremely high end systems.

    Adding an Active Treble/Bass Circuit

    Many people would like to be able to tweek the sound characteristics of a signal that they are amplifying or mixing. There is quite a lot of related math to this, however not that many parts are required to add this functionality. The following circuit requires that there be a pre-amp stage before it and another amplifier stage after it.NOTE: The 2 variable resistors should be Audio Taper (Log taper), however Linear taper will work if thats all you have available.
    And it will have a frequency response that matches the following curves:

    Block Diagram of Complete System

    I've used this circuit on PA mixers as well as musical instrument amplifiers. Its not hard to utilize, and it fits in like this:

    Sample Pre-Amp Stage with Trim Control

    NOTE: The Trim Control variable resistor should be Audio Taper (Log taper), however Linear taper will work if thats all you have available.

    Sample 2 channel Mixer Stage

    NOTE: The Level Control (seperate Volume Control) variable resistors should be Audio Taper (Log taper), however Linear taper will work if thats all you have available.
      lease be aware that this discussion is aimed at the Pro-Audio area, and is not intended for Audiophiles or other areas of circuit design outside of the Pro-Audio environment. The concepts are generally the same, if not identical. However the topic area is vast and the intent of this discussion is quick and effective practical usage - not theory, advanced or extremely high end systems.

      Adding an Active Cross-Over Network Circuit

      Sometimes you want to Bi-Amp your system (ie. a seperate Power Amp for the Mids/Highs and one for the Bass/Lows), or when you are recording, you simply want to split off the 2 frequency ranges (this is handy, since you rarely want to add much Reverb to Bass, where you might want some on the Mids/Highs).
      (The same function but at 4000 Hz)
      And it will have a frequency response that matches the following curves:

      Sample Passive input Stage to Active Cross-Over

      If you don't need anything fancy, you only need to add a few components in order to allow you to use the Active Cross-Over by itself (ie. you already have a Mixer that you want to conect this to). Add the following as the input, and you are done:
      It will operate in this fashion:

      Sample 2 channel Mixer Stage that Drives Active Cross-Over

      NOTE: The Level Control (seperate Volume Control) variable resistors should be Audio Taper (Log taper), however Linear taper will work if thats all you have available.If you want to add the Active Cross-Over to an existing Mixer, or if you are building your own Mixer, it would be added as part of the circuit, being driven off of the output of the Op-Amp in the Final Mixer stage, like:
      It could operate in this fashion:
      See Part 4 - Active Tone Controls if you would like to see how to add Tone Controls to this type of design.
      source : http://colomar.com/
OpAmp Audio 4.5 5 Mustika Nata Tunggal Operational Amplifiers (Op-Amp) were originally developed to build Analog Computers (and many Computer systems used in Aircraft still u...