Author Topic: Routing Analog/Digital traces  (Read 2253 times)

DIY Bass

Routing Analog/Digital traces
« on: December 18, 2017, 05:11:38 AM »
I am designing a board.  I know that in general you try and keep analog traces away from digital ones to stop noise from clocks etc getting into the analog.  What I am trying to do need to have pots controlling analog functions such as volume etc on one end of the board.  I would normally put all the analog components on that end of the board and digital on the other end.  I have a switch though that needs to be front panel mounted, and has no way of mounting except the PCB pins, so I am aiming to use the pots at one end and the stomp switch at the other to hold it all in place, so that the switch pokes up where it needs to go and is well supported by the PCB.  That would mean routing analog signals from the stomp switch past the digital circuitry to the analog portion and then back again.  I am basically doing a version of the Femtoverb circuit if that helps.  Is that likely to be OK, or am I taking a huge risk that it will be noisy?

Thanks

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #1 on: December 18, 2017, 05:45:57 AM »
There's no way you'll know until you try it, tbh. There's theory and experience that might give you some clues.

In general, as long as you keep the traces well spaced and avoid running the analog traces alongside high speed digital ones, it should be ok. Remember not everything that's "digital" is bad - some digital lines might spend virtually all their live in one state or the other - they won't make much noise.
If it's a two-sided layout, putting things that need to be separate on opposite sides of the board can help a bit too. I solved a problem with the version 1 VCDO PCB like this.

You're right to be cautious and think about it, but don't let that stop you trying it.

HTH,
Tom

DIY Bass

Re: Routing Analog/Digital traces
« Reply #2 on: December 18, 2017, 06:59:18 AM »
Thanks.  I will look at it carefully then and give it a go.  I only really get one shot at it.  I have 2 chipsets and need to make 2 pedals, so if one doesn't work I am a bit in trouble.  The Alesis chipset has the processor, and and A/D converter and D/A converter.  There is a crystal that connects to the processor, and data and clock lines that run between the 3 chips.   Sound like if I avoid running analog near those lines then I should be safe.  If I do have to run analog and digital beside each other, then what is the safe spacing?  you mention a double sided board - is a board thickness a good guide for spacing?

vigilante397

Re: Routing Analog/Digital traces
« Reply #3 on: December 19, 2017, 01:45:59 PM »
How many layers is your board? Are internal planes an option?

It is always good practice to keep analog and digital signals separate, and keeping them on different layers with a ground plane between them can be a very good option. Obviously not always possible, but just a thought.
"I'm not sure what "serious design flaws" you see. Does it explode or poison your dog?" - PRR

www.sushiboxfx.com

Ice-9

Re: Routing Analog/Digital traces
« Reply #4 on: December 19, 2017, 03:29:11 PM »
Try and keep your analogue and digital grounds separated until they get back to the power section ground.
www.stanleyfx.co.uk

It's fairly straight forward, if you want to start it , press start. You can work out the rest of the controls for yourself !

vigilante397

Re: Routing Analog/Digital traces
« Reply #5 on: December 19, 2017, 04:12:39 PM »
Try and keep your analogue and digital grounds separated until they get back to the power section ground.

That too. And then only one connection point between them.
"I'm not sure what "serious design flaws" you see. Does it explode or poison your dog?" - PRR

www.sushiboxfx.com

DIY Bass

Re: Routing Analog/Digital traces
« Reply #6 on: December 20, 2017, 05:52:25 AM »
I am aiming for a single layer board, but I may go for 2 layers if I need to.  On the schematic I have separate ground and digital ground joined by a 0 ohm resistor, which I think I will just solder as a jumper.  I have read in a few places that having a single jumper connection between the 2 grounds works well.

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #7 on: December 23, 2017, 01:54:28 PM »
On the schematic I have separate ground and digital ground joined by a 0 ohm resistor, which I think I will just solder as a jumper.  I have read in a few places that having a single jumper connection between the 2 grounds works well.

That's what I did on the DigiDelay board. There was some problematic hiss, but it certainly wasn't caused by that. The grounding and PCB layout seemed good.

Tom

DIY Bass

Re: Routing Analog/Digital traces
« Reply #8 on: January 24, 2018, 06:08:03 AM »
OK, reopening this because I have a few questions.  On the board I am looking at connecting analog ground and digital ground together at the digital chips.  The board that I am using as inspiration for this has done the same thing.  It turns a really complicated board with heaps of vias into something much simpler. The original build thread on here doesn't mention any difficulties with noise, so I am hopefully assuming that following the same design practice will turn out OK.  At the moment I am treating the analog ground at the chips as if it was digital ground - those pads are connected to digital ground but not to the rest of the analog ground.  What I am wondering is whether that is the best approach, or whether I should just connect the whole lot into the ground pour.  Which is more likely to be the safest option?

Thank you

wavley

Re: Routing Analog/Digital traces
« Reply #9 on: January 24, 2018, 09:36:54 AM »
New and exciting innovations in current technology!

Bone is in the fingers.

EccoHollow Art & Sound

eccohollow.bandcamp.com

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #10 on: January 24, 2018, 02:00:29 PM »
"I am treating the analog ground at the chips as if it was digital ground - those pads are connected to digital ground but not to the rest of the analog ground"

Wot?!? Sorry, I think I need a picture!
I'm not understanding the situation at all. :-[

T.

DIY Bass

Re: Routing Analog/Digital traces
« Reply #11 on: January 24, 2018, 05:12:35 PM »
Oops, sorry.  Not very clear is it?

I am doing up a variation of this http://www.diystompboxes.com/smfforum/index.php?topic=42305.20

The original PCB design had the A GND and D GND pins of the digital IC's connected together and so they are all just treated as basic GND.  Nobody on that thread complains about noise so I assume that scheme works fine in this case. 

When I was looking at a board design, it made sense to do the same thing, because it led to a a much less complicated design, so I have all the A GND and D GND pins on those IC's connected together.   So far, I am treating them all as if they are D GND - they are all pretty isolated from the main GND (which is a copper pour over most of the board) and only connected by a single jumper - so all the GND pins for the digital IC's are connected together, but only connect to GND in one place.  I was wondering if I should leave it that way, or should I just extend the copper pour into where the digital IC's are and just make all those GND pins part of the ground plane.  Hopefully that makes more sense.

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #12 on: January 24, 2018, 06:18:11 PM »
It's a fairly simple circuit, so perhaps it isn't that fussy. In general, you wouldn't want to treat the two grounds as the same thing. You'd keep them both separate all the way back to one point back at the power supply where they finally meet up. Like that, there's only a single way for noise from the digital side to get to the analog side, and it has to "go the long way around".
Depends a lot how much hash the digital circuits dump onto the rails, I suppose. If the answer is "not much", then you probably don't care (and I do this with the PIC's ADC all the time - using the same 5V and ground supply for the processor as the pots I then connect to the ADC). If it becomes a problem, then more serious measures need to be taken.

HTH,
Tom

DIY Bass

Re: Routing Analog/Digital traces
« Reply #13 on: January 25, 2018, 12:27:43 AM »
OK, I looked at it again and decided that I would do a separate digital ground.  Needed to run it on the bottom and have a via for each pad that needed to be connected, but I decided that isn't too bad seeing as I will be sending the board out so I don't have to try and manufacture it at home.  Last Q I have then is I have a ground pour on the top side.  I don't really need a difference power supply pour on the bottom, so do I make that a ground pour as well, or that overkill and just leave it as a bare board with traces?

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #14 on: January 25, 2018, 06:18:17 AM »
If you've got plenty of tracks to route, the "ground pour" on the bottom will get so snipped up into little pieces that it won't do much good anyway. I'd minimise the amount of stuff you've got on the top and have good solid ground planes on that layer, separate for the analog and the digital areas.

DIY Bass

Re: Routing Analog/Digital traces
« Reply #15 on: January 25, 2018, 06:31:17 PM »
Awesome, thanks.  That's pretty much what I have done.  The digital IC's are surface mount, so the traces around them pretty much have to be on top.  As much as possible I have put everything else on the bottom and left the top as a ground plane.  That also means that it is pretty much in sections -
 The digital is on top and the analog is on the bottom. Thank you for all your advice.

ElectricDruid

Re: Routing Analog/Digital traces
« Reply #16 on: January 27, 2018, 02:32:00 PM »
I hope it comes out well for you. I'm no layout expert, but it seems like I'm the only person willing to stick their neck out! ;)

Tom

DIY Bass

Re: Routing Analog/Digital traces
« Reply #17 on: January 27, 2018, 11:19:56 PM »
Thanks, I'll update when it's together.  I'm going to wait a few days and check it every so often just to see if I have forgotten anything (latest update was to remove the corners so it would fit around the corner posts in the box - almost forgot to do that :-) ) then I'll send it out to be made.  I have used a gerber viewer to have a look at what the finished board would look like and it seems to be about right.  Fingers crossed.