2
\$\begingroup\$

Ok so here's the deal:

I have a variable DC Voltage source from 0-10V.

I need to step that down to a variable source of 0-3V.

This 0-3V DC will be fed to an Analog to Digital converter in a microcontroller.

I know I can potentially use a Voltage Divider (using resistors) but apparently, that's not a good solution.

Op-amps don't provide a gain < 1.

So I'm just struggling as to how I can accomplish this.

The microcontroller: https://www.microchip.com/wwwproducts/en/PIC18F47K42

\$\endgroup\$
  • \$\begingroup\$ How can you use a voltage of 0 to 3V as the supply voltage for a microcontroller? Your description of this doesn't make any sense. You should draw a schematic. \$\endgroup\$ – Elliot Alderson Mar 14 at 22:04
  • \$\begingroup\$ @ElliotAlderson you're right I'm sorry. It's not to power the microcontroller. The application is to simulate dimming, based on the 0-10V from the DC Source the voltage must be stepped down from 0-3V. This is the voltage range readable by the uC which will determine the duty cycle of a PWM used to dim an LED. \$\endgroup\$ – Alee321 Mar 14 at 22:10
  • 2
    \$\begingroup\$ A resistive divider is fine then. You might want to put an op-amp voltage follower in between the divider and ADC input to buffer things but it's not always necessary. Search this site. There are many existing answers addressing your question. \$\endgroup\$ – Toor Mar 14 at 22:12
  • 3
    \$\begingroup\$ A voltage divider may be a perfectly good solution provided (a) the source impedance isn't too high and (b) you can tolerate the small energy consumption. Your question doesn't include details of either. \$\endgroup\$ – Transistor Mar 14 at 22:12
3
\$\begingroup\$

R divider works fine as long as R is not too high.

If you know the conversion rate and Hold Cap acquisition time

**strong text** EQUATION 36-1: ACQUISITION TIME EXAMPLE in the datasheet provides the formula and example of choosing R values < 10k.

Rs is the source equivalent // resistance of the R divider, R1//R2.

\$\endgroup\$
2
\$\begingroup\$

A resistor divider works fine as long as the source impedance is low and the ADC impedance is high (compared to the resistors used for the divider).

If your source impedance is high, use an opamp in voltage follower mode (gain = 1) before the divider. If your ADC impedance is low (unlikely) use a voltage follower after the divider.

\$\endgroup\$
  • \$\begingroup\$ ADCs can have low input impedances, because those sample-and-hold circuits have a capacitor that needs to be charged! A tiny one, but it's still there. Too high a resistance can mean you need to sample for longer, slowing your reads, which may or may not be acceptable. \$\endgroup\$ – Hearth Mar 14 at 23:33
1
\$\begingroup\$

In addition to @Toor suggestion (voltage follower and voltage divider) and in response to OP statement

Op-amps don't provide a gain < 1.

follows my alternative configuration using a single supply difference amplifier. The output is reversed - if you do not mind correct it in software applying \$V_o=3 - 0.3V_i\$.

ADC Level Shifter - Dirceu

\$\endgroup\$
  • 1
    \$\begingroup\$ As opposed to my voltage follower suggestion, this one has better common-mode rejection at the expense of inverting the signal. \$\endgroup\$ – Toor Mar 14 at 23:55
  • \$\begingroup\$ Are those resistor values correct? I think it's supposed to be more along the lines of 6.66K/3.33K, or 10K/5K or something like that. \$\endgroup\$ – Toor Mar 14 at 23:59
  • \$\begingroup\$ I think that it's correct. Try to apply superposition to inputs 10 V and Vi. \$\endgroup\$ – Dirceu Rodrigues Jr Mar 15 at 0:18

Your Answer

By clicking "Post Your Answer", you agree to our terms of service, privacy policy and cookie policy

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