How to divide voltage without losing any resolution.

Discussion in 'Embedded Systems and Microcontrollers' started by Gerardog2000, Sep 4, 2015.

  1. Gerardog2000

    Thread Starter New Member

    Jan 23, 2015
    13
    0
    Hello,
    I have a project that I am working on that involves an Arduino, and an external 16-bit analog to digital converter. I am testing op-amps and I need the output of the op-amp to go into the analog to digital converter. The problem is that the ADC card can only handle 2-5.5Vdc while the output of the op-amp will be around 10.24V. My question is how can I drop the output voltage of the op-amp without losing any accuracy? Right now my idea is to use a simple voltage divider where I can do a simple line of code in the arduino program to bring that voltage back up to the exact value that was at the output of the op-amp. For example, if my output voltage is 10.239789, I would like to divide that voltage by a certain number (depending on my resistors) and then be able to multiply it in my program to get back that 10.239789.

    Would that voltage divider work? Should I make it a voltage divider with a buffer? Or is there a better option? Thank you for your time.
     
  2. ScottWang

    Moderator

    Aug 23, 2012
    4,850
    767
    Could attach your circuit, so the members here have the same target to talk to?
     
  3. pwdixon

    Member

    Oct 11, 2012
    488
    56
    As long as you chose the resistor dividor such that the input impedance of the A/D doesn't load the dividor you should be able to divide down and software multiply up with no problems. Accuracy is down to using the entire range of the A/D.
     
  4. Gerardog2000

    Thread Starter New Member

    Jan 23, 2015
    13
    0
    This is part of the circuit that involves this question. pwdixon, thank you for the response. You don't recommend that include a buffer after the divider? Thanks again.

    Capture.JPG
     
  5. shteii01

    AAC Fanatic!

    Feb 19, 2010
    3,377
    494
    Put a buffer between output of voltage divider and ADC?
     
  6. KMoffett

    AAC Fanatic!

    Dec 19, 2007
    2,574
    230
    I think you would need a 17-bit ADC to get the same resolution with 10V divided down to 5V, as you would get with 5V into a 16-bit ADC. A voltage divider will only give you half the resolution, and a buffer will just add another source of error. Remember your output is in discrete digital steps. Think about it. A 5v, 1bit ADC can only distinguish between 0V or 5V. The same 1-bit ADC following a 2-to-1 divider can only distinguish between 0V or 10V.

    Ken
     
    Last edited: Sep 4, 2015
    #12 likes this.
  7. #12

    Expert

    Nov 30, 2010
    16,248
    6,744
    Exactly what I was thinking. Every stage is a possible source of error and getting a buffer below 40 uV of offset error is a chore in itself.

    (Based on 5.5V/2^17)
     
    Last edited: Sep 4, 2015
  8. ScottWang

    Moderator

    Aug 23, 2012
    4,850
    767
    Is this a homework, probably the newbies and students will use 741, it's too old to do this, specially the voltage of output low is too high, I think at least it has 1.2V, it means that the 0~1.2V will be gone from the output, how do you handle the 0V~1.2V for the ADC?
     
  9. #12

    Expert

    Nov 30, 2010
    16,248
    6,744
    This does look like student level work. The LM741 is configured to multiply by 5.1209677 and the voltage divider is set to divide by eleven. If the output of the op-amp is 10 volts, the ADC will see 0.93 volts at its input.

    The LM741 can not do this without a negative voltage for its Pin 4 (V-).
    There is no circuit attached to null the inputs of the LM741, but the measurement needs to be accurate within +/- 0.0001526 volts. (Based on 10V/2^16)

    Meanwhile, the ADC is labeled as a 12 bit converter.
    Lots of doubts here.
     
  10. Gerardog2000

    Thread Starter New Member

    Jan 23, 2015
    13
    0
    1. You guys are correct, this is student level work but it is not homework. we were given a project that runs 2 semesters. The project is open ended and we can take any direction that we chose. We are allowed to use any resource and are allowed to ask questions and use whatever is already out there.
    2. The ADC in the picture is labeled as a 12 bit converter but I can assure you that it is actually 16 bit. I took the Eagle schematic from Adafruit. Adafruit says that both the 12 bit and 16 bit are identical physically and spec wise with the exception that they are different resolution. Because of this, they only made one set of Eagle drawings and that is what you see in the picture above. The model listed in the picture is the model for the 16 bit. I will have to go into Eagle and change Adafruit's drawing to say 16 bit.
    3. You are correct, my divider is incorrect as it is. The ADC can only handle an input voltage of 2-5.5Vdc so we will have to change the divider to be within that range.
    4. I assure you that we do have a negative supply to V- and I did not attach the rest of the circuit because my question was only pertaining to the voltage divider.
    If this sounds a bit snippy then I am sorry. That was not my intent. As you can see, my concern is losing some resolution when I step down my voltage. And that was what my question pertained to. Because we are testing other model op-amps (LM741, OP-27E, and others) as well, we cannot lose any resolution and from what you guys have said, a simple divider WITHOUT a buffer would be best. A buffer will add more unnecessary error.

    Thank you for all of your help. You guys are awesome.
     
  11. joeyd999

    AAC Fanatic!

    Jun 6, 2011
    2,673
    2,712
    Dither the input and average the digital result.
     
    OBW0549 likes this.
  12. Gerardog2000

    Thread Starter New Member

    Jan 23, 2015
    13
    0
    I'm sorry, I don't understand your comment.
     
  13. joeyd999

    AAC Fanatic!

    Jun 6, 2011
    2,673
    2,712
    For example.
     
    ScottWang and OBW0549 like this.
  14. OBW0549

    Well-Known Member

    Mar 2, 2015
    1,300
    879
  15. joeyd999

    AAC Fanatic!

    Jun 6, 2011
    2,673
    2,712
  16. #12

    Expert

    Nov 30, 2010
    16,248
    6,744
    This statement keeps popping up, and I wonder if it is being misinterpreted. The ADC has a Vcc range of 2V to 5.5V. I don't think it has an input range that won't work down to zero volts.
     
  17. Gerardog2000

    Thread Starter New Member

    Jan 23, 2015
    13
    0
    You are right, the supply voltage should be between 2-5.5Vdc but the analog input can definitely read down to zero. The spec for the analog input is from VDD + 0.3Vdc so the input signal MUST not exceed the 5.8Vdc or the board will get damaged.

    As far as dithering goes, I'm not sure that we can implement it correctly. Seems a bit above our current level. I understand that it would increase our resolution but it may pose too difficult for us to implement. Thanks again for the help.
     
    Last edited: Sep 5, 2015
Loading...