The following circuit is an active current to voltage converter with switchable gain.
Not shown: The inverting input is held low through a 10K resistor when the circuit is powered on but not being used. Whenever a measurement is being made (including calibration measurements where IN is floating), that resistor is disconnected.
Supplies on the analog switches and opamp are +/- 11.5 V. The typical VOUT range is between -10V and +10V.
The circuit is used to measure currents in the nanoamp range. A few mV on the output is significant. Constant offsets are not really a problem, as they can easily be calibrated out by measuring the output with an open input and subtracting that from subsequent measurements.
Each board has 6 or more of these circuits.
The selected op amp has very small (< 10 pA) offset and bias input currents and a very small offset voltage (< 1 mV). It's an AD8625AR.
SW1A and SW1B are different poles of the same CMOS switch (ADG1236). They are switched together to select the feedback resistor, which determines the gain of the converter. The maximum leakage current is 1 nA on source and drain pins, on or off. The switch not shown (for holding the inverting input low through a 10K resistor) has similar performance. Typical leakage currents are very small (< 0.1nA).
The problem I am having is that in some batches of boards, some (or all) of these circuits have large offsets which decay slowly when powered on. However, most boards are perfectly stable at all times, with small offsets.
A typical offset on VOUT with IN floating is < 1 mV. On afflicted boards, the offset can be as high as 120 mV.
When the afflicted boards are powered on, the offset will slowly (after hours of days) stabilize to ~5 mV. After power is removed, the offset accumulates again, so when powering it on after a couple days of being off, it's high again.
Each board has a bunch of these circuits on it. In the first batch of 5 boards, all of them were affected. In the next batch, none were affected. In the most recent batch, each board has one affected circuits, and it isn't always the same one.
At the worst case, the maximum leakage currents of all the analog switches would be 1.2nA, resulting in a 12 mV offset at the highest gain setting, so I don't think that can account for all the offset I'm seeing.
Where else could the offset voltage be coming from? Is there a common board defect that would result in this sort of behavior?