Picking the right op-amp.

Thread Starter

Bod

Joined Sep 18, 2016
301
Hopefully this is the last ever post I have to make on this topic of op-amp and audio and whatnot. I've accepted my fate and I'm going to redesign my whole circuit board (I believe its got a cracked trace or something and I'm totally over debugging it).

For the most part (peak detectors, high / low pass filters) I'm happy with what I have. they use the good-old cheap LM358 and they work like a charm. (May be worth getting a chip that is only one channel to save having to do something with the un-used op-amp pins)

The main change is the audio bias and gain section of my board. What it does is it uses a LT1366 to bias the signal at +2.5 (and add a bit of amplification) and since it's rail-to-rail it can swing between 0 and 5V.
I was informed that the LT1366 is a very noisy op-amp. It is also overkill (because I over-complicated my circuit) and expensive for what I need.
What the whole board does is that it takes an audio signal and biases it at 2.5V (swings 0 - 5V). it then sends that signal through circuits like peak detectors. Then on the output of those circuits I use a voltage divider to now make it so the signal is at 1.75V (so now it now swings between 0 and 3.3V).
It's so totally over-complicated when I could just bias it at 1.75V in the first place. That also means I dont need a rail-to-rail op-amp.

The TLDR here is that I need an op-amp that is low noise, can support single supply and if it's not rail-to-tail it can at least support up to 3.3V out. It would also be nice if it had a Spice model.
I did some research and found the LMH6629 and SE5532AD8G. The LMH6629 is good because it's single channel and therefore I don't need to worry about the other channels. It seems like it would be a bit hard to find thought. Same goes for the SE5532AD8G.
I also looked at my old post and the MCP6002 / MCP6001 was mentioned. Although it's rail-to-rail, it is low noise and cheap (and has a Spice model).

It seems like a good choice but before I get too ahead of myself like I did last time, has anyone got any other good suggestions?
 

Thread Starter

Bod

Joined Sep 18, 2016
301
I had a good read through the post and noted down some that I liked the sound of. I then put them into a table with a bit of data like slew rate and noise.
Out of them all, I think the OPA197 is the best choice. It's rail-to-rail, cheap, it's low noise and has a high slew rate.
Thank you for the thread it was very helpful!
 

Thread Starter

Bod

Joined Sep 18, 2016
301
I have one quick question. At the moment, I am using 2 2-channel op-amps for my circuit. If I were to use the OPA179 I would have 2 1-channel op-amps. Is there any downside to using just 1 2-channel op-amp and taking advantage of both channels? Would that affect the amount of noise and whatnot?
 

OBW0549

Joined Mar 2, 2015
3,515
I have one quick question. At the moment, I am using 2 2-channel op-amps for my circuit. If I were to use the OPA179 I would have 2 1-channel op-amps. Is there any downside to using just 1 2-channel op-amp and taking advantage of both channels? Would that affect the amount of noise and whatnot?
I can't think of anything wrong with doing that. There might be a small amount of crosstalk between channels; check the data sheet.
 

Thread Starter

Bod

Joined Sep 18, 2016
301
I can't think of anything wrong with doing that. There might be a small amount of crosstalk between channels; check the data sheet.
The data sheet of the OPAx197 doesn't seem to mention anything of crosstalk. I am I ok to assume that that means it is not an issue then?
 

OBW0549

Joined Mar 2, 2015
3,515
The data sheet of the OPAx197 doesn't seem to mention anything of crosstalk. I am I ok to assume that that means it is not an issue then?
I would think so; in any case, channel-to-channel crosstalk is more likely to be a function of your circuit board layout than anything else.
 

Thread Starter

Bod

Joined Sep 18, 2016
301
I would think so; in any case, channel-to-channel crosstalk is more likely to be a function of your circuit board layout than anything else.
Surprise surprise there's a lot of good info on a data sheet. And some important stuff too! I am definitely going to read through things like recommended board layouts and do my best to follow them. Even just things like adding a 0.1uF bypass cap between Vcc and GND isn't something I would have done had I have not read the datasheet (like my last attempt).

Anyway I think that's cleared everything up now so thank you!
 

OBW0549

Joined Mar 2, 2015
3,515
Surprise surprise there's a lot of good info on a data sheet. And some important stuff too!
Yup, and nearly all of it is important in one case or another. Judging by what I've seen here on AAC, one of the things people seem to ignore (or aren't aware of) most often in their designs is an op amp's input voltage range (a.k.a. input common-mode voltage range): it's why their poor little 741 op amp fails to do anything at all when powered by a single +5V supply.

I am definitely going to read through things like recommended board layouts and do my best to follow them.
Good idea. There are an almost limitless number of ways to screw up a circuit board layout. Three of the most popular seem to be:
  • Running tracks carrying high-level, high dV/dT signals right next to tracks connecting an op amp's inputs to its related components;
  • Ignoring the paths that currents take on the board, and allowing high current, high dI/dT signals to flow through sensitive analog sections of the circuit; and
  • Doing boneheaded stuff like placing components willy-nilly all over the board, with no regard to signal integrity. I actually saw a circuit board once where the layout dude had place a microcontroller over in one corner of an 8.5" x 11" circuit board, and its 16 MHz oscillator crystal in the diagonally opposite corner. Board didn't work. Duh.
I'm sure other people here can cite many, many more goofs that people sometimes make in layout out circuit boards.

Even just things like adding a 0.1uF bypass cap between Vcc and GND isn't something I would have done had I have not read the datasheet (like my last attempt).
Rule To Never Be Disobeyed: every IC should have a bypass cap across its supply terminals. ALWAYS. NO EXCEPTIONS. Ceramic caps are cheap. Engineer/technician time to debug a misbehaving design is not. Nor is having to revise a layout to add the missing capacitors.

Anyway I think that's cleared everything up now so thank you!
You're welcome.
 

Thread Starter

Bod

Joined Sep 18, 2016
301
Doing boneheaded stuff like placing components willy-nilly all over the board, with no regard to signal integrity. I actually saw a circuit board once where the layout dude had place a microcontroller over in one corner of an 8.5" x 11" circuit board, and its 16 MHz oscillator crystal in the diagonally opposite corner. Board didn't work. Duh.
Almost exactly what I did. The components aren't all willy-nilly. I actually layed them out in groups quite neatly. This issue is this guideline from a datasheet:
* Keep the length of input traces as short as possible. Always remember that the input traces are the most sensitive part of the circuit.
Yeah. I didn't do that. Although its neat there's so much wasted space and parts of the circuit are so far away from others making the traces unnecessarily long.
I'm sure in multiple places this guideline wasn't followed either:
* In order to reduce parasitic coupling, run the input traces as far away from the supply or output traces as possible.
I think I will manually route the board this time so I can try and follow this to best of my ability.

EDIT: The moment I picked up the board I noticed a power trace running parallel to a signal trace with about 2mm of gap between the two. Probably not so good.
 

OBW0549

Joined Mar 2, 2015
3,515
I think I will manually route the board this time so I can try and follow this to best of my ability.
I always manually route boards. To me, autorouters are practically useless.

EDIT: The moment I picked up the board I noticed a power trace running parallel to a signal trace with about 2mm of gap between the two. Probably not so good.
Not necessarily a bad thing, if the voltage on the power trace is well-regulated and free of noise and transients. Still, to be avoided if possible.
 

cmartinez

Joined Jan 17, 2007
7,063
EDIT: The moment I picked up the board I noticed a power trace running parallel to a signal trace with about 2mm of gap between the two. Probably not so good.
Separating those two traces a little bit more, and adding a ground trace between them, could be the easiest way to improve things significantly without reworking the entire design.
 
Last edited:

dl324

Joined Mar 30, 2015
11,317
EDIT: The moment I picked up the board I noticed a power trace running parallel to a signal trace with about 2mm of gap between the two. Probably not so good.
That's actually a good thing. Microprocessor designers run critical signals parallel to power, typically at minimum space, whenever they can because they get favorable parasitics. Without shielding, they need to use larger than minimum line spacing (2X or more) which costs area.
 

Thread Starter

Bod

Joined Sep 18, 2016
301
Not necessarily a bad thing, if the voltage on the power trace is well-regulated and free of noise and transients. Still, to be avoided if possible.
I'm not sure how noise my power supply is to be honest. There's no harm in doing so especially because of all the extra space I gave myself.
Separating those two traces a little bit more, and adding a ground trace between them, could be the easiest way to improve things significantly without reworking the entire design.
It's not a very well designed board so I already am going to rework it. Since it's not at all complicated I will manually route it so I can really make sure I've got it all correct. How well would a ground plane work rather than a ground trace?
 

cmartinez

Joined Jan 17, 2007
7,063
How well would a ground plane work rather than a ground trace?
Much better. And even more if you use both. Another important issue is to make sure that the ground from the analog part of the circuit runs separately from the ground from the digital side. And both should meet at one point only. Using two separate ground planes for the analog and digital parts of the circuit is also good practice.
 

Thread Starter

Bod

Joined Sep 18, 2016
301
Much better. And even more if you use both. Another important issue is to make sure that the ground from the analog part of the circuit runs separately from the ground from the digital side. And both should meet at one point only. Using two separate ground planes for the analog and digital parts of the circuit is also good practice.
When you say "digital side" what do you mean. I know what digital is and what it means but if I have a lots of op-amps that would constitute as analog and then they get fed into a microcontroller. I don't use any digital output from the microcontroller so would that mean I have no "digital side"?
Also, last time I made this I used one of these DC-DC isolating converters. I used it to isolate the power to the microcontroller from the power to the op-amps. So the only connection between the two was the input pins going into the microcontroller. Other than that they were completely separated. Would it be useful to use that again?
Here's some good stuff on grounding and decoupling:
Thanks! will have a good read of these and make my circuit as good as it can get.
 

cmartinez

Joined Jan 17, 2007
7,063
When you say "digital side" what do you mean. I know what digital is and what it means but if I have a lots of op-amps that would constitute as analog and then they get fed into a microcontroller. I don't use any digital output from the microcontroller so would that mean I have no "digital side"?
What I meant was that you should design your circuit layout so that all of the digital components are on one side of it, and the analog ones on the other. It could be a left and right configuration, or a top and bottom one, doesn't matter. What matters is that you should segregate those components so that they don't share the same area in your board.

Also, last time I made this I used one of these DC-DC isolating converters.
I wouldn't use those converters as power sources for analog circuits if I were you. Those are switch mode power supplies and are extremely noisy and will make it difficult to get clean signals from your analog components. It's best to use a linear type power supply for analog purposes. Even an old fashioned 7805 (properly filtered) is a better choice.

OB is far more knowledgeable than I am on this subject. In fact, he's been mentoring for the last few years, and most of the things I know about this field I owe to him. I'm sure his insight will prove to be much more valuable than mine.
 

OBW0549

Joined Mar 2, 2015
3,515
I don't use any digital output from the microcontroller so would that mean I have no "digital side"?
If you don't use any of the outputs from the microcontroller, then what in the world is it doing?? Surely it must be doing something...

Also, last time I made this I used one of these DC-DC isolating converters. I used it to isolate the power to the microcontroller from the power to the op-amps.
Be very, VERY wary of those things, especially the cheap ones. They can produce huge amounts of noise on both the output and input pins, and if you don't use them correctly they can easily make things worse instead of better.
 
Top