Current flowing through wiring will develop voltage drops that shift the supposed “ground” reference to something other than the desired “0” point.
The problem is not just an analog ground versus digital ground problem.
common ground for Analog and Digital
It can rear its ugly head in almost any analog circuit, and can even in all-digital circuit. It is, however, particularly prevalent in mixed analog, digital systems. Ground wires serve two different functions. Sometimes they are used to carry currents. At other times you want the ground to serve as a rock-solid reference point for making precision measurements. This is especially true in A/D circuits with more than 8 bits of desired resolution. The best way to handle the ground problem is to have different ground systems that connect at only one point. The
precision analog REFERENCE ground should always be designed so that an absolute minimum of current actually flows through it. In practice this is accomplished by having all reference ground connections terminating at a single point.
Firstly, all MEASUREMENT ground connections should use individual traces that converge at a single REFERENCE POINT. The idea is to not allow any current flow through one reference trace to affect any other reference trace. What you want to avoid is having one long trace that snakes all over the board, with many different ground connections being made at different points along this trace. The currents will add up, causing different voltages to appear along the trace.
Secondly, all GROUND POWER supplied to the analog section should use another ground system. This ground system should have a single connection to the REFERENCE ground point.
Thirdly, a COMMON ground connection to any major DIGITAL GROUND system should also be made to the single REFERENCE ground point. If properly constructed, the REFERENCE ground point becomes a nice rock solid point from which measurements can be made. It will be COMMON to all other system grounds, but this common connection should NOT itself experience any current flow. Or at least the current flow should be absolutely minimal. In extremely noisy systems the analog section may be floated or isolated from other sections. In this case data is communicated from one section to another via opto-isolators, transformers, or using other isolation techniques.
Complete isolation is also desired in medical systems where even small currents can do great damage to a patient. The tendency when laying out a printed circuit board is to just run a ground trace around the board and have all kinds of things attach themselves to this running ground. But if you desire precision measurements one must have a precision reference POINT to which ALL measurements are referenced.