Shop OBEX P1 Docs P2 Docs Learn Events
Sigma-Delta ADC — Parallax Forums

Sigma-Delta ADC

bob kruggelbob kruggel Posts: 50
edited 2010-12-08 09:41 in Propeller 1
I have been attempting to build a Sigma-Delta ADC and have finally succeded after reading multipule objects from obex, prop tool examples and forums. The main confusion factor was the different component values from different sources. I confirmed the need to keeps leads as short as possible and that changing component values will change the ADC results. What I haven't found is a way to predict the values I will get from a set of components. An option would be a description of a method of calibrating the ADC, and a way to understand the repeatability of a particular circuit. I.E. How to make the circuit useable. Can someone shead some light?
Bob Kruggel

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-12-07 09:54
    To make the sigma-delta ADC truly useful, you need to configure your circuity to do an automatic calibration at the beginning of your setup routine. There are two ways to do this:

    1. Commit an extra Prop pin and connect it ahead of the ADC's RC network. If you can't tri-state your analog source, add a current-limiting resistor ahead of the extra pin. (This method is used in the Propeller Backpack.)

    2. Use an analog multiplexer ahead of the ADC's RC network. One multiplexer input will come from your analog source, with one connected to Vdd, and another connected to Vss. (This method is used in the S2 robot.)

    Now, suppose you want 8-bit resolution. At the beginning of your ADC setup routine, set your integration time to some initial value, and take a pair of readings: one with the input connected (or forced) to Vdd; the other, to Vss. Subtract one from the other. If the value is greater than 255, decrease the integration time and try again. If it's less than 255, increase the integration time. You can do this using a binary search to speed things up. (See the S2 object for an example.) At the end, you'll have two values: the correct integration time, and a reading for Vss.

    Then, when you need to take a reading, integrate for the calibrated integration time, take a reading, then subtract the reading for Vss. Finally, limit your reading to the range 0 .. 255 using the <# and #> operators. (There will always be a little noise in the system that produces outliers.)

    -Phil
  • Bill HenningBill Henning Posts: 6,445
    edited 2010-12-07 09:59
    Great post Phil.

    It explains the inputs I saw on the S2 schematic :)
  • RaymanRayman Posts: 14,889
    edited 2010-12-07 10:43
    There's an applet to help pick component values here:
    http://www.pulsedpower.net/Applets/Electronics/SigmaDeltaADC/SigmaDelta.html
  • bob kruggelbob kruggel Posts: 50
    edited 2010-12-08 09:12
    Rayman,

    Do you have anything that describes how the formula in the Applet were derived, or more info in general?

    Bob Kruggel
  • RaymanRayman Posts: 14,889
    edited 2010-12-08 09:41
    Not really...
    But, if you do "View Text" on that page and then scroll down, you can see the source code...
Sign In or Register to comment.