Electronics > Projects, Designs, and Technical Stuff
differential Op-amp with 1V offset design difficulties
(1/4) > >>
SeaMaster:
I have something that I thought is a trivial problem and I have been trying to resolve for a while now with no success, thus I decided to reach out to you for help.

I’m trying to create a little device that will measure voltage 0-32VDC (preferably -32V to +32VDC so in this way no polarity needs to be observed when connecting to voltage source)
Im truing to accomplish that by providing an offset of about 0.9V from the output of the differential op-amp.
There is an issue with the ADC converter of the uC that I’m using. It has a dead band from 0V to 0.15V therefore will not measure in this range. The full scale of the ADC input (linear) is about 2.4V. So ideally I’m trying to stay in the boundaries of 0.15V to 1.95V on the input of the ADC and have a middle point 1.05V if possible to be able to measure positive and negative voltages. I’m trying to offset the input to the ADC so I can do proper measuring starting from 0V to 1.8V.
I hope that makes sense, but to summarize I need to have:
Single 3.3V power to the op-amp.
Input of the op-amp from -32V to +32V
Output of the op-amp 0.15V when -32V and 1.95V when +32V. I should be able to measure with or without the negative input of channel 1 or channel 2 connected to ground.

I tried to do it the following schematic (resistors are not calculated for the voltages indicated above):

Unfortunately with my offset improvisation on differential amplifier schematic only “kind of” works. The R5 and R13 resistors are there for illustration of what happens if I try to measure shared ground sources. Let's presume the R5 and R13 are not in place first. If I have the input open, I get starting point of the ADC (12bit) about 940 on both channels.  If I connect the input to a PS and start increasing the voltage it works as expected and I can get the ADC value rising with the voltage rising until I reach 4095 saturation value. If I connect the PS in reverse, I get the value of the ADC to decrease. Obviously I’m not quite in the middle but that can be rectified easy. So far, so good.
The issues start when I add any R5 or R13 resistors simulating that the power source and the voltage source share the same ground. immediately I get the value of the ADC with nothing connect the op-amp input, increase from 940 to about 1,115. Obviously that can’t be good. I figured that in this case, grounding the negative input of the schematic will bring the potential of the op-amp negative inputs 1IN- and 2IN- to 0V vs. the 0.9V that I’m having there when R5 or R13 are not in place. This is a result of the op-amp trying to compensate for the offset voltage. 


So how do I avoid that shift and have an offset on the output of the op-amp to allow me to take proper measurement with the ADC?
Is there a way to do an offset with a single stage op-amp and allow me to ground an inout without the shift?

Do I have to create two stages, where the first stage is simple diff op-amp scenario getting fed 0 to +32V and outputting 0-1.8V and feeding that into second stage buffer op-amp that will shift the output to 0.15V to 1.95V? This I think will work except I can’t connect the input in reverse and measure it.
Is it possible to measure -32V to +32V or should I stick with 0V to 32V on the inputs?

Is there a simple (or not that simple ) way to accomplish what I need with single VCC3.3V power to the op-amp?

I hope that you can help,
Thank you in advance for your time,
exmadscientist:
I don't see why a bog-standard difference amplifier wouldn't do the job. See the attached LTspice simulation results. (Note that to actually build this you'd want to find E96 resistors in the shown ratio -- but using these values shows you where the ratio comes from.)

It looks like you can achieve about -16V to +60V of common mode range on your inputs with a +/-32V differential input, assuming a full RRIO op-amp.

As to why you're having trouble, are you sure that your R5 and R13 do what you think they're doing? Why do you think that's the right way to "simulate sharing a ground"?
MarkF:


Vbias can be (+) or (-) depending on which direction you need to move the bias point.

I used the configuration on the left by driving Vbias with a DAC and op-amp to offset the output of a signal generator.
The op-amp (TL082) converts DAC output of 0-4V to +/-2V.

Example:
SeaMaster:

--- Quote from: exmadscientist on November 14, 2019, 05:20:36 am ---I don't see why a bog-standard difference amplifier wouldn't do the job. See the attached LTspice simulation results. (Note that to actually build this you'd want to find E96 resistors in the shown ratio -- but using these values shows you where the ratio comes from.)

It looks like you can achieve about -16V to +60V of common mode range on your inputs with a +/-32V differential input, assuming a full RRIO op-amp.

As to why you're having trouble, are you sure that your R5 and R13 do what you think they're doing? Why do you think that's the right way to "simulate sharing a ground"?

--- End quote ---
the issue is that if I don't have an isolated PS powering the schematic and the power is coming from the same power source I want to measure then inevitable the Vin- gets connected to the ground. in the moment that happens, there is a significant shift in the ADC value. As I indicated in my case it is from 940 to 1115 on 12bit ADC.
the problem is even more pronounced if I have multiple channels and they all measure the voltages that share the same ground...
this is exactly what I'm trying to resolve but don't know how...
SeaMaster:

--- Quote from: MarkF on November 14, 2019, 05:48:23 am --- (Attachment Link)

Vbias can be (+) or (-) depending on which direction you need to move the bias point.

I used the configuration on the left by driving Vbias with a DAC and op-amp to offset the output of a signal generator.
The op-amp (TL082) converts DAC output of 0-4V to +/-2V.

Example:
(Attachment Link)

--- End quote ---
But this is exactly what I have done on my schematic, isn't it? I have the issue when the one of the input connects to ground. It creates shift into the ADC. it is to be expected as the amplifier reacts to the grounding of the input by changing the output to compensate the offset. So if I'm to read the voltage from little 9V battery not connected to my ground it works ok. If I'm to read the voltage of the battery I power the device from , I need to connect the ground to the Vin- and we get a shift (in my case from 940 to 1115 ADC 12bit) so I think that in general the offset works, but I don't  think the offset /bias work in my case. So I need some other solution to overcome the problem with multiple channels inputs when connected together or to common ground to prevent shifting from happening.
Navigation
Message Index
Next page
There was an error while thanking
Thanking...

Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod