What are some good PCB layout tips?
Submitted By: Craig Steiner FAQ Last Modified: 11/30/08
- Keep the crystal and burden capacitor tracks shortest. Do not connect the ground pins of 33pF capacitors to ground plane. Connect them directly to microcontroller ground.
- Do not encircle the crystal with signals. It'll couple noise to whatever you connect. Run them on the same side of the crystal. And put a shield trace between the crystal signals and those I/O. If they go any distance, consider an R/C filter (47R and 0.001 uF depending on their speed).
- Ground-fill under the crystal might improve emissions. If you do ground-fill, it needs to be properly anchored.
- Route solid ground planes on both sides of PCB, if you use double sided PCB do not use solid Vcc plane, but ground planes on both sides, and lot's of vias between them.
- In critical situations, especially if very high clock frequencies are used, the two burden capacitors can be soldered directly across pins of microcontroller. By this any copper traces are omitted 'by design'. The crystal is then connected by as short traces as possible.
- It must be kept in mind, that all these currents, which flow in the crystal circuit will flow back to the ground pin of microcontroller. And so, there must always exist an as perfect as possible connection of involved ground pins of crystal circuit (ground pins of burden capacitors) to the ground pin of microcontroller! But not enough, also all ground return currents caused by charging of stray capacitance must be fed directly to ground pin of microcontroller. And the housing of quartz IS a source of stray capacitance, which must be grounded adequately!.
- Try to avoid 90 degree bends on your tracks. Using two 45 deg bends (or a radius) reduces EMI.
- Don’t weave tracks from your outside world through the cpu side. Not a good idea - try and maintain as much separation as possible - even to the point of using small pads on the optocoupler and don't run tracks between the optocoupler. You're wanting the opto to give you voltage isolation so don't compromise it with your pcb.
- It can help to surround the microcontroller circuit on top layer by a guard trace (which is connected to ground plane, maybe by vias).
- Ground plane extended over all signal traces in combination with guard trace arround certain points act as a shield, as if you have put the whole board into a metal enclosure. And this by only using a solid ground plane without making compromises.
- Ground plane also provides a ground return current path for every signal trace next to it, and by this heaviliy minimizing created loop and as result, radiation from this signal trace and susceptibility against radiation.
- Ttwo different digital signals must always be separated by certain distance, so that toggling of one line will not propagate to other line due to charge injection via stray capacitance. If both digital lines are very close to each other and you toggle one of the lines very quickly, then you will notice a very fast spike on the other superimposed to its signal. If noise margin is violated then you will have trouble.
- One way to prevent such cross coupling is to shield the different signals to each other, by routing a solid ground plane between them.
- Another way to shield these signals, is to route them over a solid ground plane. But this is only helpful, when distance to solid ground plane is heavily decreased, like it is used with multilayer boards. It can be calculated, that the stray capacitance between the signals decreases to the same amount as the capacitance between signal and ground plane increases. Multilayer boards provide a very effective shielding between digital signals by this methode.
- Sometimes it can be seen, that bus signals are routed very close to each other, even when no ground plane is very close underneath. As long as the signals belong to the same bus, where all signals are simultaneously clocked, means toggled, then a bit stray capacitance can be allowed if source impedance of drivers is very low and bus timing is not too fast. Then, injected charge due to cross coupling can be removed again before data on bus is latched.
- If you route a digital signal over a solid ground plane, then the ground return current will always flow directly underneath the signal current, not elsewhere on the board. This is especially valid for the high frequency content of signal. It can be shown, that by this current flowing scheme resulting magnetic field is minimal. And as inductivity is defined as produced magnetic flux per current, this also results in a heavily minimized inductivity of according signal traces.
- When using a Two layer board try not to run tracks on top and bottom exactly one over the other try to keep the extent of overlapping among top and bottom tracks minimum. As this overlapping causes sharp spike in the trace when the overlapping track is toggled.
Refering to point number 7
Submitted By: AP charles FAQ Last Modified: 11/30/08
- I found a contradiction to this clause number 7: where 90 degrees bending may be a contradiction.
http://69.41.174.64/forum/read.phtml?id=74595
Add Information to this FAQ: If you have additional information or alternative solutions to this question, you may add to this FAQ by clicking here.