Close

21.5 Bits!

A project log for 22-bit Capacitance to Digital Converter

A new capacitance displacement sensor interface for my seismometer with improved performance and low cost.

Bud BennettBud Bennett 07/16/2019 at 13:312 Comments

Another C2D board to play with:

Built a second C2D using noise optimized components and TP07 opamps. The TP07 opamps are quite a bit less expensive than the OPA376 opamps, but the common mode range of the TP07 inputs is GND to VCC - 2V, so the COMMON bias voltage was dropped to 1.53V. The full scale range of the C2D converter is not affected because a ±4pF capacitance change at the input produces ±1.44V at the output.

I verified that the C2D was operating correctly and generating appropriate full-scale output voltages by connecting a 4.7pF capacitor between the two CAP inputs and EXC pins. This second board even has an offset voltage with the inputs unconnected that is within a few mV of the first board.

When I connected the new C2D to a Raspberry Pi 3B+ with nothing connected to the inputs, the resulting noise waveform was a bit disappointing. The peak-peak count variation was less than 10, but there was a -15 count spike that occurred with a period of exactly 60 seconds. I made sure that there were no other daemon programs of mine running that would cause this kind of interference. Varying the sample rate of the C2D had no effect on the 60 second spike. The standard deviation of the ADC output was around 2 counts, which is 18.5 bits of NFDNR.

I then connected the C2D to a Raspberry Pi Zero-W, again with no inputs connected. This time the output waveform noise was much worse -- 20 counts p-p -- but the 60 second spike disappeared. So now I have some evidence that the C2D board is being influenced by its proximity to the RPi.

Getting Some DIstance:

I found a 6-inch long ribbon cable with 0.1 inch header sockets on both ends that I used to separate the C2D from the RPi. I also added copper foil shielding and foam insulation to the C2D board. Things improved a lot, but there were still some strange drift in the output that I could not explain. This disappeared when I connected the GND of the C2D to earth ground.

Here's the output of the C2D connected to the RPi-3B+, sampled at 2 sps and bandpass filtered to 0.01Hz - 0.5Hz: 

I dumped the waveform data to ascii and imported it to a spreadsheet to extract the standard deviation -- 0.7344 bits, or 21.54 bits of noise-free dynamic range! That's right inline with the design target.

When connected to the RP--ZeroW, the raw output over 10 minutes (1200 samples) looks like this (the ZeroW doesn't have a ringserver installed):

This is unfiltered data, which includes a small amount of temperature drift, but the p-p variation is 6 counts. Again, the NFDNR is 21.5 bits when averaged down to 1 sps (equivalent to the filtered BW of the previous data.)

(I must declare at this point that I did not expect to ever see the output of a 24-bit ADC with just a ±2-count wiggle -- that's only 0.12ppm!)

Diet Cola Experiment is Ongoing:

The seismometer with the first C2D board (unshielded without insulation) has been running for a few days now. It still hasn't settled to a recognizable equilibrium, but it seems to be getting closer. Here's the raw data over the last 1.5 days:

I'm expecting the 24-hr peak-peak swing to be less than 50,000 counts. Prior to the diet cola the swing was about 300,000 counts. This has to be a good thing. Here's the above data with a 0.01Hz - 0.5Hz bandpass applied:

There is a bit of increased noise as the raw waveform changes direction from rising to falling. I wish that I could divine the mechanism that causes this. It seams to be less pronounced than pre-diet-cola. The spiking could also be associated with some monsoon weather that is a regular occurrence this time of year. I will let it go for a few more days before making any conclusions.

Next Steps:

  1. Complete the diet cola testing.
  2. Replace the first C2D with the second C2D which has copper shielding, insulation and ribbon cable.

Discussions

Bharbour wrote 07/16/2019 at 17:04 point

What would lightning activity in the area look like on the C2D output?

  Are you sure? yes | no

Bud Bennett wrote 07/16/2019 at 17:46 point

Lightning would be a single spike per event. It is difficult to keep it out of the grounding systems. But wind noise in the nearby trees would cause surface disturbances that are detectable. A "normal" seismometer is usually set in a bore hole more than 100 feet underground to eliminate temperature and surface effects.

  Are you sure? yes | no