Through hole 2/4 layer PCB design-Hints,Tips and best practice. - Page 1
Forum section: electronics / projects

author: djsb
author_rank: Super Contributor
timestamp: December 28, 2023, 03:22:08 pm
content: I'm starting to lay out a 2 layer through hole PCB prototype using Altium designer 21.4.1. This is the first time I've used Altium as I usually use KiCad. My schematic uses hierarchical blocks, and I'm importing each block into the PCB one at a time. I need to decide on how to handle the layout. Is a full ground plane on the top layer (with holes for component leads only) and signal and co-planer ground on the bottom layer OK? Is it best practice to use via stitching between the ground on the top and bottom layer? There will be a small dual rail power supply included as well, but I've not designed this yet. I've included the schematic below. Any advice welcome. Thanks.PS I don't want to go by default to a 4 layer board as I have no experience with them. As this is a prototype, I want to use 2 layers and keep the cost down.PPS I'll probably use something like these dual rail power supply ideashttps://sound-au.com/project43.htm

author: berke
author_rank: Frequent Contributor
timestamp: December 28, 2023, 04:28:14 pm
content: If you use only one plane for routing this circuit you will end up with very contorted routes which will probably cancel whatever benefit you might get from a full ground plane.In addition it's not always a good idea to have ground planes everywhere with analog circuits, as that produces significant capacitive coupling to the ground (easily in the tens to hundreds of pF), this can cause feedback stability issues depending on your circuit.Personally I would place the components in a way similar to the schematic, route the signals using both planes and do a GND copper pour on both sides with stitching. Try to place the transistor pairs close together so they are at the same temperature. If needed add exclusion zones around sensitive areas such as op-amp inputs or the differential pairs. You may even need to keep some subcircuits apart and put guard rings around them or enclose them in cans.Have you thought of replacing the through-holes with SMDs? Larger SMDs are very easy to solder and much more pleasant to work with if you're soldering them manually IMHO, you don't have to hold the components and flip the board all the time.

author: djsb
author_rank: Super Contributor
timestamp: December 28, 2023, 05:25:18 pm
content: Would it be beneficial to use matched transistor pairs, if only for the fact that the pairs will be in close thermal contact?There are these AS394 from Alfa in Latvia. There are more expensive alternatives (THAT300,SSM2212 etc)https://www.ericasynths.lv/media/AS394CH.pdfI might go the SMD route to get some experience.

author: berke
author_rank: Frequent Contributor
timestamp: December 28, 2023, 05:49:22 pm
content: Quote from: djsb on December 28, 2023, 05:25:18 pmClearly. In addition to thermal contact the pre-matched pairs will have similar gain and other parametrs. I would expect that mismatches would translate to unbalanced mixing, with the subcarrier no longer being suppressed for example. But it may or may not be worth it depending on what you're trying to do.You have to make sure the transistor pairs are more or less compatible with the ones called for in the schematic. You could simulate the circuit with models for the recommended transistors and models for your pairs.QuoteInteresting, happy to see that some semiconductors are still made in Europe. Do they provide SPICE models? If not you can wing it by picking transistors that are close enough to the listed specs. I don't think anything is critical, this is a low-frequency application. What are your expectations?Quote

author: shapirus
author_rank: Super Contributor
timestamp: December 28, 2023, 06:10:49 pm
content: btw, SMT, even if it might seem counterintuitive, is actually easier for DIY boards: to begin with, you have much less holes to drill....although since you mentioned 4-layer boards too, I guess you won't be making them yourself.

author: djsb
author_rank: Super Contributor
timestamp: December 28, 2023, 06:19:48 pm
content: I generally make at least one prototype to make sure the circuit actually works first, and would do them on an LPKF router at work. Then, if it's worth the effort, I would try getting a 4 layer board done at Aisler. I'd prefer keeping it to 2 layer as it will keep the costs down. This whole excercise is to get some experience using Altium and I can also get some experience with SMD parts.

author: berke
author_rank: Frequent Contributor
timestamp: December 28, 2023, 06:28:35 pm
content: Quote from: djsb on December 28, 2023, 06:19:48 pmInteresting machines. Can it make vias? How fast is it? It probably costs as much as a small car.

author: djsb
author_rank: Super Contributor
timestamp: December 28, 2023, 06:41:16 pm
content: It doesn't do VIA's unfortunately. Cost around £30k. Very useful for prototyping and proof of concept work, and faster than a board can be delivered. We use it for student PCB prototypes and for initial prototypes of PCB's we use for teaching (that I design using KiCad).

author: sparkydog
author_rank: Regular Contributor
timestamp: December 28, 2023, 07:01:44 pm
content: Quote from: berke on December 28, 2023, 04:28:14 pmIn my experience, this ("you will end up with very contorted routes") isnotnecessarily the case. That said, component placement is definitely something of a black art. Given 4-layer boards can be 10x the cost of 2-layer boards, IMHO it's at least worth trying. (For that matter, I've run into instances where trying to turn a 2-layer board into a 4-layer board just made thingsworse, at least with THT boards that turn all layers into Swiss cheese.)Quote from: berke on December 28, 2023, 04:28:14 pmI'd second that, but it depends on the component. This works fine for basic stuff like resistors, capacitors and transistors. Not so well for relays, and I wouldn't recommend pure-surface-mount for terminals.

author: djsb
author_rank: Super Contributor
timestamp: December 29, 2023, 11:09:07 am
content: Got myself 10 off Alfa AS394 NPN matched pair and 3 off AS395 PNP matched pairs. The AS394's are in SOIC and the AS395's are TO5-8 (circular metal can-not available in SOIC). They were on sale at Thonk who sell Analogue Synth parts in the UK. They were mentioned by Alfa when I asked them for a UK dealer. Alfa also sells directly, but probably expect large orders (I didn't ask for a minimum order). I've attached the datasheets below. I'll probably crack on with the layout in KiCad as it has a T05-8 footprint, and I've not learnt footprint creation in Altium yet.

author: berke
author_rank: Frequent Contributor
timestamp: December 29, 2023, 12:12:15 pm
content: Quote from: sparkydog on December 28, 2023, 07:01:44 pmIt's true that with through-hole it's easier as you can route many traces under resistors, even adjust their lengths or place them vertically, and bridge distant traces with 0Rs.If you stick to SMD, and if you're not allowing yourself super-fine traces, it becomes really hard pretty quickly.In both cases with single-layer layouts you often spending lots of time placing, rotating and re-placing components. Maybe if you master the black art you can do it very quickly, but when I do it I generally end up having to cheat by adding a few jumper wires to finish the design. Planar graphs are rare.Do you have examples of heroic single-layer artwork?If you don't have too many constraints (size and such) I believe two layers with vias makes things almost always routable (even if ugly), and you spend 1/5th the time compared to single-layer work. With 4 and 6 layers I think basic routability stops being the main issue, you can place your connectors and components in a sensible way, count on at least one good ground plane and focus on other issues such as parasitics, thermals and avoiding stupid footprint mistakes.QuoteFor external terminals especially heavy-duty ones such as screw terminals I agree. For low power internal or board-to-board connections that will only see a few mating cycles SMD should be fine. If you look at a PC motherboard you'll see that lots of connectors are SMD.With home-made PCBs I use 0.1" SMD pin headers, they take up more space and are not as robust but I prefer that to drilling 40 holes. Also, edge SMA connectors are pretty mechanically robust if you solder them on both sides as you should.SMD versions of some connectors sometimes have a plastic peg or notch that fits in a hole and provides mechanical strength against pulling. You only have to drill one hole. For example there are DC power jacks.For prototyping, soldering some wires to pads is the easiest.

author: shapirus
author_rank: Super Contributor
timestamp: December 29, 2023, 12:43:58 pm
content: Quote from: berke on December 29, 2023, 12:12:15 pmBesides, home-made holes are not metal-plated, which makes it difficult to route traces to/from the pin header on the same layer that it sits on. So you have to solder them on the opposite side and either route there, or drill another set of holes and route them back to the top using pieces of tinned wire.The best solution to this, unless there is an easy way to create metal-plated holes (I would love to hear if there is one) is probably what was mentioned in the original post: use one side for ground plane and through hole components and the other side for SMD components and signal routing.

author: djsb
author_rank: Super Contributor
timestamp: December 29, 2023, 02:23:32 pm
content: It looks like my design will predominately be SMD components apart from the AS395 which is an 8 pin TO5-8 package. This has 8 leads in a circular pattern and a metal can. I suppose this could be mounted with the leads through holes but only soldered on the TOP layer and the BOTTOM layer pads ISOLATED. I could also use the leads of the AS395 as VIA's. This circuit is working at less than 100KHz, but I want to get the grounding and EMI side done properly.

author: shapirus
author_rank: Super Contributor
timestamp: December 29, 2023, 03:24:38 pm
content: Quote from: djsb on December 29, 2023, 02:23:32 pmYeah absolutely. When there is an exposed length of leads and the body does not sit right on the board, covering the holes, then it's easy to solder them on either side.Another option to mount THT components is to bend the leads and solder them on the surface without any holes at all. This however often requires to create your own footprints, but it's not too hard, especially given that you can take an existing THT footprint and change the type of the pads to SMT (and adjust the shape and size accordingly, if necessary).

author: djsb
author_rank: Super Contributor
timestamp: December 29, 2023, 08:16:50 pm
content: I might use one of these Mill-Max sockets (the SMD version) for the AS395https://www.mouser.co.uk/datasheet/2/273/MMMCS33714_1-2552648.pdfhttps://www.mouser.co.uk/ProductDetail/Mill-Max/917-93-108-41-005000?qs=teNCaa%2FZ3avwnlnQx1IWlA%3D%3D&mgh=1&vip=1&gad_source=1That is, as long as I make the vertical space available.