Loading ...
Sorry, an error occurred while loading the content.

ADC question

Expand Messages
  • Ron Clough
    Anybody know the magic incantations required to use the Vref- and Vref+ inputs on a PIC18F2620? The ADC is working when the Vref- and Vref+ inputs are disabled
    Message 1 of 6 , Jun 2, 2005
    • 0 Attachment
      Anybody know the magic incantations required to use the Vref- and
      Vref+ inputs on a PIC18F2620?
      The ADC is working when the Vref- and Vref+ inputs are disabled so
      that the ADC does a conversion over the range Vss to Vcc.
      However, when both Vref- and Vref+, or only Vref+, are enabled the
      results are ridiculous!
      For example,
      Vref+ = 3.3V, Vref- = 1.6V,
      input signal to be converted = 2.4V,
      ADC result = 0x03FF, ie. full-scale!

      Any help would be appreciated,
      RonC
    • tellurian
      Ron, How are you generating + & - Vref? They should be very low impedance 50 ohms or less. For example the MCP1541 (MicroChip s 4.096V reference) has an output
      Message 2 of 6 , Jun 2, 2005
      • 0 Attachment
        Ron,

        How are you generating + & - Vref? They should be very
        low impedance 50 ohms or less. For example the MCP1541
        (MicroChip's 4.096V reference) has an output impedance
        of way less than 6 ohms. The reference must be able to
        deliver a quick pulse of current to recharge internal
        capacitor arrays for each conversion. I use +Vref all
        the time with an MCP1541 or MCP1525 and have excellent
        results. If you are just using a voltage divider ...
        try switching to a zener (with about 2-5 mA reverse
        bias current) ... OR ... buffer the references with an
        opamp.

        If you are generating Vref with a pot that could
        explain the saturated readings (i.e. the internal
        capacitors never get to charge up ... so the ADC input
        always looks high with respect to what it is trying to
        compare against).

        ??

        Allen M.

        --- Ron Clough <ronclough@...> wrote:

        > Anybody know the magic incantations required to use
        > the Vref- and
        > Vref+ inputs on a PIC18F2620?
        > The ADC is working when the Vref- and Vref+ inputs
        > are disabled so
        > that the ADC does a conversion over the range Vss to
        > Vcc.
        > However, when both Vref- and Vref+, or only Vref+,
        > are enabled the
        > results are ridiculous!
        > For example,
        > Vref+ = 3.3V, Vref- = 1.6V,
        > input signal to be converted = 2.4V,
        > ADC result = 0x03FF, ie. full-scale!
        >
        > Any help would be appreciated,
        > RonC
        >
        >
        >




        __________________________________
        Discover Yahoo!
        Find restaurants, movies, travel and more fun for the weekend. Check it out!
        http://discover.yahoo.com/weekend.html
      • Ron Clough
        Thanks Allen, I m using a resistor voltage divider! I ll try buffering with op-amps. Cheers, RonC ... it out!
        Message 3 of 6 , Jun 2, 2005
        • 0 Attachment
          Thanks Allen,
          I'm using a resistor voltage divider!
          I'll try buffering with op-amps.
          Cheers,
          RonC


          --- In ORE_bits@yahoogroups.com, tellurian <i_tellurian@y...> wrote:
          > Ron,
          >
          > How are you generating + & - Vref? They should be very
          > low impedance 50 ohms or less. For example the MCP1541
          > (MicroChip's 4.096V reference) has an output impedance
          > of way less than 6 ohms. The reference must be able to
          > deliver a quick pulse of current to recharge internal
          > capacitor arrays for each conversion. I use +Vref all
          > the time with an MCP1541 or MCP1525 and have excellent
          > results. If you are just using a voltage divider ...
          > try switching to a zener (with about 2-5 mA reverse
          > bias current) ... OR ... buffer the references with an
          > opamp.
          >
          > If you are generating Vref with a pot that could
          > explain the saturated readings (i.e. the internal
          > capacitors never get to charge up ... so the ADC input
          > always looks high with respect to what it is trying to
          > compare against).
          >
          > ??
          >
          > Allen M.
          >
          > --- Ron Clough <ronclough@s...> wrote:
          >
          > > Anybody know the magic incantations required to use
          > > the Vref- and
          > > Vref+ inputs on a PIC18F2620?
          > > The ADC is working when the Vref- and Vref+ inputs
          > > are disabled so
          > > that the ADC does a conversion over the range Vss to
          > > Vcc.
          > > However, when both Vref- and Vref+, or only Vref+,
          > > are enabled the
          > > results are ridiculous!
          > > For example,
          > > Vref+ = 3.3V, Vref- = 1.6V,
          > > input signal to be converted = 2.4V,
          > > ADC result = 0x03FF, ie. full-scale!
          > >
          > > Any help would be appreciated,
          > > RonC
          > >
          > >
          > >
          >
          >
          >
          >
          > __________________________________
          > Discover Yahoo!
          > Find restaurants, movies, travel and more fun for the weekend. Check
          it out!
          > http://discover.yahoo.com/weekend.html
        • tellurian
          Just out of curiosity ... ... __________________________________ Discover Yahoo! Have fun online with music videos, cool games, IM and more. Check it out!
          Message 4 of 6 , Jun 2, 2005
          • 0 Attachment
            Just out of curiosity ...
            ... what resistance values ar you using?

            --- Ron Clough <ronclough@...> wrote:

            > Thanks Allen,
            > I'm using a resistor voltage divider!
            > I'll try buffering with op-amps.
            > Cheers,
            > RonC
            >
            >
            > --- In ORE_bits@yahoogroups.com, tellurian
            > <i_tellurian@y...> wrote:
            > > Ron,
            > >
            > > How are you generating + & - Vref? They should be
            > very
            > > low impedance 50 ohms or less. For example the
            > MCP1541
            > > (MicroChip's 4.096V reference) has an output
            > impedance
            > > of way less than 6 ohms. The reference must be
            > able to
            > > deliver a quick pulse of current to recharge
            > internal
            > > capacitor arrays for each conversion. I use +Vref
            > all
            > > the time with an MCP1541 or MCP1525 and have
            > excellent
            > > results. If you are just using a voltage divider
            > ...
            > > try switching to a zener (with about 2-5 mA
            > reverse
            > > bias current) ... OR ... buffer the references
            > with an
            > > opamp.
            > >
            > > If you are generating Vref with a pot that could
            > > explain the saturated readings (i.e. the internal
            > > capacitors never get to charge up ... so the ADC
            > input
            > > always looks high with respect to what it is
            > trying to
            > > compare against).
            > >
            > > ??
            > >
            > > Allen M.
            > >
            > > --- Ron Clough <ronclough@s...> wrote:
            > >
            > > > Anybody know the magic incantations required to
            > use
            > > > the Vref- and
            > > > Vref+ inputs on a PIC18F2620?
            > > > The ADC is working when the Vref- and Vref+
            > inputs
            > > > are disabled so
            > > > that the ADC does a conversion over the range
            > Vss to
            > > > Vcc.
            > > > However, when both Vref- and Vref+, or only
            > Vref+,
            > > > are enabled the
            > > > results are ridiculous!
            > > > For example,
            > > > Vref+ = 3.3V, Vref- = 1.6V,
            > > > input signal to be converted = 2.4V,
            > > > ADC result = 0x03FF, ie. full-scale!
            > > >
            > > > Any help would be appreciated,
            > > > RonC
            > > >
            > > >
            > > >
            > >
            > >
            > >
            > >
            > > __________________________________
            > > Discover Yahoo!
            > > Find restaurants, movies, travel and more fun for
            > the weekend. Check
            > it out!
            > > http://discover.yahoo.com/weekend.html
            >
            >
            >




            __________________________________
            Discover Yahoo!
            Have fun online with music videos, cool games, IM and more. Check it out!
            http://discover.yahoo.com/online.html
          • Ron Clough
            VCC ... 100k ... +--- Vref- ... 50k pot ... GND and VCC ... 50k pot ... +--- Vref+ ... 100k ... GND ... out!
            Message 5 of 6 , Jun 2, 2005
            • 0 Attachment
              VCC
              |
              100k
              |
              +--- Vref-
              |
              50k pot
              |
              GND

              and

              VCC
              |
              50k pot
              |
              +--- Vref+
              |
              100k
              |
              GND


              --- In ORE_bits@yahoogroups.com, tellurian <i_tellurian@y...> wrote:
              > Just out of curiosity ...
              > ... what resistance values ar you using?
              >
              > --- Ron Clough <ronclough@s...> wrote:
              >
              > > Thanks Allen,
              > > I'm using a resistor voltage divider!
              > > I'll try buffering with op-amps.
              > > Cheers,
              > > RonC
              > >
              > >
              > > --- In ORE_bits@yahoogroups.com, tellurian
              > > <i_tellurian@y...> wrote:
              > > > Ron,
              > > >
              > > > How are you generating + & - Vref? They should be
              > > very
              > > > low impedance 50 ohms or less. For example the
              > > MCP1541
              > > > (MicroChip's 4.096V reference) has an output
              > > impedance
              > > > of way less than 6 ohms. The reference must be
              > > able to
              > > > deliver a quick pulse of current to recharge
              > > internal
              > > > capacitor arrays for each conversion. I use +Vref
              > > all
              > > > the time with an MCP1541 or MCP1525 and have
              > > excellent
              > > > results. If you are just using a voltage divider
              > > ...
              > > > try switching to a zener (with about 2-5 mA
              > > reverse
              > > > bias current) ... OR ... buffer the references
              > > with an
              > > > opamp.
              > > >
              > > > If you are generating Vref with a pot that could
              > > > explain the saturated readings (i.e. the internal
              > > > capacitors never get to charge up ... so the ADC
              > > input
              > > > always looks high with respect to what it is
              > > trying to
              > > > compare against).
              > > >
              > > > ??
              > > >
              > > > Allen M.
              > > >
              > > > --- Ron Clough <ronclough@s...> wrote:
              > > >
              > > > > Anybody know the magic incantations required to
              > > use
              > > > > the Vref- and
              > > > > Vref+ inputs on a PIC18F2620?
              > > > > The ADC is working when the Vref- and Vref+
              > > inputs
              > > > > are disabled so
              > > > > that the ADC does a conversion over the range
              > > Vss to
              > > > > Vcc.
              > > > > However, when both Vref- and Vref+, or only
              > > Vref+,
              > > > > are enabled the
              > > > > results are ridiculous!
              > > > > For example,
              > > > > Vref+ = 3.3V, Vref- = 1.6V,
              > > > > input signal to be converted = 2.4V,
              > > > > ADC result = 0x03FF, ie. full-scale!
              > > > >
              > > > > Any help would be appreciated,
              > > > > RonC
              > > > >
              > > > >
              > > > >
              > > >
              > > >
              > > >
              > > >
              > > > __________________________________
              > > > Discover Yahoo!
              > > > Find restaurants, movies, travel and more fun for
              > > the weekend. Check
              > > it out!
              > > > http://discover.yahoo.com/weekend.html
              > >
              > >
              > >
              >
              >
              >
              >
              > __________________________________
              > Discover Yahoo!
              > Have fun online with music videos, cool games, IM and more. Check it
              out!
              > http://discover.yahoo.com/online.html
            • Ron Clough
              Wooo Whooo . . . Allen, you re a genius :) Buffering the references solved the problem. With Thanks, RonC ... Check
              Message 6 of 6 , Jun 2, 2005
              • 0 Attachment
                Wooo Whooo . . .
                Allen, you're a genius :)
                Buffering the references solved the problem.
                With Thanks,
                RonC


                --- In ORE_bits@yahoogroups.com, "Ron Clough" <ronclough@s...> wrote:
                > Thanks Allen,
                > I'm using a resistor voltage divider!
                > I'll try buffering with op-amps.
                > Cheers,
                > RonC
                >
                >
                > --- In ORE_bits@yahoogroups.com, tellurian <i_tellurian@y...> wrote:
                > > Ron,
                > >
                > > How are you generating + & - Vref? They should be very
                > > low impedance 50 ohms or less. For example the MCP1541
                > > (MicroChip's 4.096V reference) has an output impedance
                > > of way less than 6 ohms. The reference must be able to
                > > deliver a quick pulse of current to recharge internal
                > > capacitor arrays for each conversion. I use +Vref all
                > > the time with an MCP1541 or MCP1525 and have excellent
                > > results. If you are just using a voltage divider ...
                > > try switching to a zener (with about 2-5 mA reverse
                > > bias current) ... OR ... buffer the references with an
                > > opamp.
                > >
                > > If you are generating Vref with a pot that could
                > > explain the saturated readings (i.e. the internal
                > > capacitors never get to charge up ... so the ADC input
                > > always looks high with respect to what it is trying to
                > > compare against).
                > >
                > > ??
                > >
                > > Allen M.
                > >
                > > --- Ron Clough <ronclough@s...> wrote:
                > >
                > > > Anybody know the magic incantations required to use
                > > > the Vref- and
                > > > Vref+ inputs on a PIC18F2620?
                > > > The ADC is working when the Vref- and Vref+ inputs
                > > > are disabled so
                > > > that the ADC does a conversion over the range Vss to
                > > > Vcc.
                > > > However, when both Vref- and Vref+, or only Vref+,
                > > > are enabled the
                > > > results are ridiculous!
                > > > For example,
                > > > Vref+ = 3.3V, Vref- = 1.6V,
                > > > input signal to be converted = 2.4V,
                > > > ADC result = 0x03FF, ie. full-scale!
                > > >
                > > > Any help would be appreciated,
                > > > RonC
                > > >
                > > >
                > > >
                > >
                > >
                > >
                > >
                > > __________________________________
                > > Discover Yahoo!
                > > Find restaurants, movies, travel and more fun for the weekend.
                Check
                > it out!
                > > http://discover.yahoo.com/weekend.html
              Your message has been successfully submitted and would be delivered to recipients shortly.