0
\$\begingroup\$

An ADC (ADS1015 with n=12 bit resolution) is connected to 5V DC power supply. So its V_ref=5V.

However, if I set gain=16, then full-scale-range = +/-0.256V i.e peak to peak voltage= V_pp=2*0.256=0.512V (as given in data sheet Pg 10, Table 3: Reference https://cdn-shop.adafruit.com/datasheets/ads1015.pdf )

In such a scenario, which formula out of the two mentioned below should be used to convert raw data from ADC into equivalent voltage:

(1) V_in = (Raw data from ADC) * (V_ref/2^n) = (Raw data from ADC) * (5/4096)

(2) V_in = (Raw data from ADC) * (V_pp/2^n) = (Raw data from ADC) * (0.512/4096)

Also, in the above two formula, where do we substitute "gain=16" factor?

If somebody could please explain this I would be very much appreciative.

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

It’s the second one. The full range of 4096 counts correspond s to 0.512 volts and so each count corresponds to 0.512/4096 volts.

\$\endgroup\$
2
  • 1
    \$\begingroup\$ Thanks a lot @Frog for your comment. ALso, plz let me where do we substitute the "gain=16" factor in this equation? \$\endgroup\$
    – Ranjan Pal
    Dec 12, 2020 at 4:59
  • 1
    \$\begingroup\$ Actually the full-scale range with gain = x1 is +/-4.096V, not 5V as you had indicated. So I think what you’re asking for is V_in = (Raw data from ADC) * (V_pp/2^n) = (Raw data from ADC) * ((8.192 /16)/4096). Does that make sense? \$\endgroup\$
    – Frog
    Dec 12, 2020 at 5:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.