namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 2, 2020 20:06:09 GMT
Over on the Discord channel there was a question about which Operational Amplifiers (op-amps) to buy. For some reason, I volunteered some feedback and here I am trying to provide some information to help those new to electronics a little What I'm going to do (and I invite others to chip in too!) is give a very high level intro and some links on various things. Hopefully it will be useful to someone, although I find that there are so many useful resources on the internet that it's basically impossible to be a definitive resource!
|
|
namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 2, 2020 20:22:46 GMT
Op-AmpsThe original question was specifically about op-amps, but if this proves useful I may write a bit about other components too (All of this is my current opinion, there is more detail, but maybe not just yet). So, what's an op-amp? At its heart, it's a very high gain amplifier which, with some surrounding resistors, can be tamed to make it a _useful_ amplifier. Wikipedia has to say this (for those that are interested) or, if you have a bit of time, try this videoSo what can you do with an op-amp? Many things, including: - amplifiers;
- mixers;
- filters;
- oscillators;
- …
I'll write about these a bit later. In the context of AE Modular, there are some things which must be considered: - Single Supply (+5v):- Typical op-amp circuits expect split supplies, which is what you'll find in Eurorack for example (+12v and -12v), designing for single supplies means that some extra considerations might be needed.
- Low voltage (+5v):- 5v does not give us very much to play with. To keep sonic performance as good as possible, we want to make our signal as large as possible (ideally signals would swing all the way from 0 to +5v).
- Low speed (audio):- op-amps can be used over a wide range of frequencies, but since we're mainly dealing with audio, we don't need to use anything with too wide a bandwidth (which means we can use cheaper devices!)
From a DiY perspective, the pinouts of op-amps are generally consistent, so a circuit can usually be designed and op-amps swapped in and out without having to redesign the circuit layout (although the performance of the circuit may of course change!) Op-amps usually exist in families - where there will be variations typically consisting of one, two or four op-amps in a single package. One example of this is the TL07x (or TL08x) family, where x can be replaced by 1, 2, or 4 (giving us part numbers TL071, TL072 and TL074). The single and dual parts are usually contained in a single 8-pin package, whilst the quad parts are usually in 14 pin packages. So, which op-amps should I buy for my experiments? Well, given the restrictions listed above we need something which will operate on a low voltage and will allow the inputs and outputs to swing to close to the supply rails. General purpose op-amps such as the LM358 ( datasheet), and the TL07x/TL08x ( datasheet) series are not perfect choices (although they are cheap and plentiful) for the following reasons: LM358 plus points: can operate on voltages between 3 and 32v; cheap; plentiful. LM358 minus points: output voltage is limited to between 0 and around 70% of the supply voltage (for a 5v supply); 1MHz bandwidth TL07x plus points: cheap; plentiful; 3MHz bandwidth TL07x minus points: Needs 10v minimum supply; output voltage is limited to between 0 and around 75% of the supply voltage (for a 5v supply) These are both pretty old designs (TL07x datasheet dates from 1978), so we can do better with more modern designs built for low voltage applications such as battery-powered audio. Here are a couple that I have played with: TLV237x ( datasheet) -- Like the TL07x series, there are single, dual and quad versions of this op-amp. TLV237x plus points: widely available; can operate as low as 2.7v; inputs and outputs can go within 0.05v of the supply; 3MHz bandwidth TLV237x minus points: not as cheap as some op-amps MCP600x ( Datasheet) -- These are another family which I use (only because they were slightly cheaper than the TLV237x series!) MCP600x plus points -- widely available; can operate from as low as 1.8v; inputs and outputs can go within 0.03v of the supply MCP600x minus points -- 1MHz bandwidth (note that there is also the MCP60x series ( datasheet) which is possibly slightly better than the MCP600x series, but for audio there's not much between them!) If you're interested in single-supply considerations when designing circuits, these PDFs have maths and graphs in them www.ti.com/lit/an/sloa030a/sloa030a.pdf?ts=1591126834928 (2001) www.ti.com/lit/an/sboa059/sboa059.pdf?ts=1591126849060 (1986) So there's a start. What do you want to build?
|
|
|
Post by slowscape on Jun 2, 2020 22:43:37 GMT
Thanks again for doing this. You note the bandwidth of each of the op-amps that you mention, can you (or someone) help illustrate for me how bandwidth relates to sound?
I understand our audible range is 20-20000Hz, how does a bandwidth of 1MHz / 3MHz relate to what we can actually hear?
|
|
namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 2, 2020 22:57:16 GMT
Thanks again for doing this. You note the bandwidth of each of the op-amps that you mention, can you (or someone) help illustrate for me how bandwidth relates to sound?
I understand our audible range is 20-20000Hz, how does a bandwidth of 1MHz / 3MHz relate to what we can actually hear?
Sure! The thing about op-amps is that their gain actually slopes off at higher frequencies; the bandwidth quoted is actually the 'unity gain bandwidth', where the op-amp is configured so that it is not amplifying at all. This translates into a thing called the 'gain-bandwidth product' (it turns out that if you multiply the gain of your op-amp circuit by the measured bandwidth you end up with a constant for each type of op-amp). So, in summary, at higher gains, the bandwidth is less, but you can work it out simply (gain * bandwidth = unity gain bandwidth). As you pointed out, our hearing only goes up to 20kHz, so given a theoretical op-amp with a bandwidth of 2MHz, we could configure the circuit with a gain of up to 100 (because 100*20000 = 2000000) without hearing any roll off of higher frequencies. If we were amplifying really quiet sounds and wanted a gain of 1000, then we would be limited to frequencies up to 2kHz, so an op-amp with a larger bandwidth would then be needed. Of course this is theoretical, so practical circuits may give slightly different results…
|
|
|
Post by admin on Jun 2, 2020 23:10:08 GMT
Thanks you namke, this is high quality information. I wonder if this could turn into a project for the DIY module?
|
|
|
Post by slowscape on Jun 5, 2020 18:58:34 GMT
I looked into the difference between single and dual supply op-amps, and see that a single supply simply clips the negative voltage. Is an op-amp the method in which the AEM clips all signals to only be positive? I ask because I've seen various circuit designs for shifting or clipping signals and they are not done with an op-amp. Attachments:
|
|
namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 5, 2020 19:35:23 GMT
Good question, I’ll write something about this soon but for now I’ll just say that we can avoid such clipping by ‘biasing’. Basically this adds a constant voltage to the incoming signal so that it is not clipped. Let’s say that we have an input signal which oscillates between -1 and +1 volts, if we didn’t bias this then the op amp would only see the positive half but by adding 1v to the signal the op amp will see a signal between 0 and 2v, which means that the waveform is not clipped. This ‘DC bias’ for audio signals is isolated by using capacitors on the input and output. I’ll write something a bit more detailed when I’m on a computer rather than my phone
|
|
|
Post by martynaudio on Jun 6, 2020 9:03:08 GMT
great thread! I'm new to a lot of the DIY side of things too, always nice having a read through to try and get my head around more of this.
|
|
|
Post by thetechnobear on Jun 7, 2020 13:35:45 GMT
interesting discussion I have to say, I was a bit 'intimidated' by op-amps when I first started, but if you place them on a breadboard, and use a voltmeter to measure output voltages they are pretty easy to play with the lesson I had to learn the 'hard way' was to use rail-to-rail opamps! rail to rail meaning ... an opamp is given two voltages, with AE, for output, this would be 0.. 5v - these are the rails, of max that the op-amp can go up and down to. obviously if we are dealing CV we want to use as much of this range as possible - and this is what 'rail to rail' opamps allow. this is why I use MCP6004 etc.... as they allow us close to this level. for audio, its not so vital, as we probably don't need 5vpp output - but if you're doing this as a hobby, and you're getting started - why bother 'stocking' different op-amps? (there is a slight cost thing here, but small scale we are probably loosing more due to shipping that component costs ) thats just my personal amateur opinion..... interesting what you are saying about bandwidth namke , as had no understanding of that... however, seems likes 1MHz it's unlikely to be an issue? for CV we are working in 0..1kHz range, so plenty of gain there. for audio 100hZ-to 20kHz range, but practically, I probably cant hear much above 10kHz (older guy ) even so, 100x gain, seems pretty high.... most of the time I've been using op-amps its to amplify MCU and similar from 3.3v to 5v, so 2x. but good to know, when to look at that bandwidth number, as never knew what it was for, and thought given my frequency ranges it was irrelevant EDIT: I think it'd be a good idea to re-title this discussion to op-amps. I think different components warrant different topics/discussions - rather than stuffing into one topic.
|
|
namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 7, 2020 14:16:07 GMT
interesting discussion I have to say, I was a bit 'intimidated' by op-amps when I first started, but if you place them on a breadboard, and use a voltmeter to measure output voltages they are pretty easy to play with the lesson I had to learn the 'hard way' was to use rail-to-rail opamps! rail to rail meaning ... an opamp is given two voltages, with AE, for output, this would be 0.. 5v - these are the rails, of max that the op-amp can go up and down to. obviously if we are dealing CV we want to use as much of this range as possible - and this is what 'rail to rail' opamps allow. this is why I use MCP6004 etc.... as they allow us close to this level. for audio, its not so vital, as we probably don't need 5vpp output - but if you're doing this as a hobby, and you're getting started - why bother 'stocking' different op-amps? (there is a slight cost thing here, but small scale we are probably loosing more due to shipping that component costs ) For sure - no point in having lots of op-amps which may or may not work in a given situation interesting what you are saying about bandwidth namke , as had no understanding of that... however, seems likes 1MHz it's unlikely to be an issue? for CV we are working in 0..1kHz range, so plenty of gain there. for audio 100hZ-to 20kHz range, but practically, I probably cant hear much above 10kHz (older guy ) even so, 100x gain, seems pretty high.... most of the time I've been using op-amps its to amplify MCU and similar from 3.3v to 5v, so 2x. but good to know, when to look at that bandwidth number, as never knew what it was for, and thought given my frequency ranges it was irrelevant You're completely right, this is unlikely to affect audio circuits, perhaps until oscillators are being built and you start wondering why are my square waves not quite square enough But that's probably a later topic!! EDIT: I think it'd be a good idea to re-title this discussion to op-amps. I think different components warrant different topics/discussions - rather than stuffing into one topic. Yes, I think you are probably right there
|
|
|
Post by NightMachines on Jun 8, 2020 6:43:47 GMT
|
|
|
Post by rodney on Jun 9, 2020 19:26:47 GMT
A good example project might be (Disclosure: I am biased because I really want to make one next) something to convert signals to and from the signal and bias level needed to feed into and out of a guitar foot pedal.
I would guess that many AE folk have a few of these ready-made 'modules' stashed away waiting for liberation. Recovering guitarists might be shy about coming forward but it's okay people, we all have dark secrets.
I found a Danelectro Daddy-O distortion (FET 'valve-sound') while sorting through crap in the garage, along with an ancient Thomas Organ Crybaby waa waa pedal that probably needs new capacitors by now. (These two sturdy chunks of aluminium probably weigh as much as my whole AE rig!)
namke, I don't want to impose on you too much. I am happy to work on converting a phone photo of a scribbled circuit diagram into something pretty with one of the circuit cad programs out there. I want to learn that anyway - and to make it into a printed circuit board design. (this goes for any example project design, not just my own pet thing)
|
|
|
Post by MikMo on Jun 9, 2020 19:55:44 GMT
Yes i want that too, even suggested it a while back.
|
|
namke
wonkystuff
electronics and sound, what's not to like?!
Posts: 686
|
Post by namke on Jun 12, 2020 16:50:51 GMT
A good example project might be (Disclosure: I am biased because I really want to make one next) something to convert signals to and from the signal and bias level needed to feed into and out of a guitar foot pedal. I have plenty of pedals too; I may be able to take a look at what it would take to feed audio in and out to them — I suspect not much is needed to be honest. I suppose it depends upon how 'quick and dirty' a solution is needed
|
|
|
Post by rodney on Jun 18, 2020 3:53:19 GMT
|
|