Measuring current using OpAmp. Broken OpAmp?

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
Hello!

I'm trying to create a simple current sensor using OpAmp as shown in the following schematic: http://tinyurl.com/y43jfjky
It all works as expected in simulation, but when I wire it up using real components, the OpAmp behaves strangely.

My real circuit has the same setup as in the simulation...
- The current through 0.1 ohm resistor is 22mA.
- Voltage on IN+ pin is 2.2 mV
- pot values are exactly as in the schematic

However, my real Opamp Always outputs around 4V, which causes IN- pin voltage to be around 400 mV.
Shouldn't the OpAmp lower the output voltage so IN+ and IN- match?
This is the OpAmp I'm using: RC4558P

This is an image of how I wired the circuit on the perfboard (the one with parralel copper lines)
CurrentSensor.PNG
(I scratched the 4 copper leads behind the OpAmp and one above the ground pin of the potentiometer.)

I had the same circuit on the breadboard yesterday and it was working (roughly). I was getting very strange values because my breadboard has couple of ohms of contact resistance, which completely screwed my measuremens. I was hoping to get better accuracy using perfboard, but now the OpAmp doesn't seem to work, and I'm not sure of anything any more :)

Does this look like a malfunctioning OpAmp to you?
Is it possible that I burned the OpAmp while soldering?

Thank you.
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
I forgot to mention two things.
- The image doesn't show the load resistor
- The current sense resistor is actualy 10 x 1 Ohm resistors in parallel.
 

shteii01

Joined Feb 19, 2010
4,644
Where is the datasheet for the opamp?
No. I am not going to google it. YOU want help, you be helpful to people YOU want help from.

The schematic you show is the conceptual schematic. It is for conveying the concept.
It IS NOT an actual circuit schematic. So. Next you will need to provide the actual circuit schematic. I don't care how you do it. Draw it on paper with a pencil. Or use Visio. Or dedicated circuit drawing program like MultiSim, LT Spice, etc.
 

ericgibbs

Joined Jan 29, 2010
18,766
hi db,
The d/s states a dual power supply is required, how is it powered.?
Also what effect do you get on the output of the OPA.?
E
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
Ty Eric.

The OpAmp is powered by 5V on the Vcc+, and GND on the Vcc-.
Is this the problem?

"Recommended operating conditions" table shows the minimum is 5V on Vcc+ and -5V on Vcc-.
I thought these are just recommended values and that anything between +15 and -15 would be OK as long as VCC+ is higher than Vcc-.
 

ericgibbs

Joined Jan 29, 2010
18,766
hi db,
That RC OPA is almost the same as the old 741, it does not work well on a single supply, its a very old specification.

Is the output showing a minimum voltage above zero of about 1v.?

E
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
Thank you.

I just tried it on the breadboard according to this schematic, and it doesn't work correctly when IN+ is lower than 800mV.

Vouiltage doubler.png

When IN+ is above 800mV, the output is doubled as expected, but when I drop it below, the output jumps to cca 4V.
I'll try to think of something else.
 

ericgibbs

Joined Jan 29, 2010
18,766
Hi,
Which ever type of single supply powered OPA you use, it will never read zero Vout for zero load current.
What is the Vout connected too.?
E
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
Out will be connected to ground through 10k pot which I'm using as a voltage divider (as shown in the schematic) It will also be connected to arduino analog IN which I will use to measure the voltage.

But I think I understand what the problem is. The inputs can't be too close to Vcc- because of minimum threshold voltage required to operate the internal transistors. I didn't think of that before your post, and now it's kinda obvious.

I will try to find the -5V line. I'm using an old PC power supply. It should have -5V somewhere :)
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
Hm, but in this case, I don't know how to bring my input voltages to above 1V level.
I guess I could put the current sense resistor in front of the load, but then OpAmp inputs will be too close to Vcc+ (I guess)
 

ericgibbs

Joined Jan 29, 2010
18,766
hi.
Assume that with no current the Vout is 800mV, now use a pot and a resistor add offset to the input, so the Vout is 1v.
Increase the input load current to its maximum value, the Vout will limit at 5Vsupply-1.5V, ie: 3.5V. [ its a poor OPA]

So 1v thru 3.5v is the Vout range.
What max current do you want measure??

E
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
I think I didn't explain it right.
In my original schematic, the output is always around 4V no matter what current goes through 0.1 ohm resistor.

As I understand that's because 800mV is the minimum voltage I need to bring to OpAmp input in order for output to do anything.
In my original example, I was trying to measure 22mA of current. This gave me 2.2mV of voltage drop across current sense resistor, which is nowere near 800mV the OpAmp needs to start working.
 

ericgibbs

Joined Jan 29, 2010
18,766
hi,
As you want to measure 0mA thru 22mA, a 0.1R Shunt resistor will only give 0mV to 2.2mV.
What voltage would like to get from the OPA output.?
With a 1k1 and 9k7 that is only 8.8+1 Gain ie; 9.8 say 10, so Vout will only be 22mV

Thats a very low input to an ADC.
E

EDIT:
I think it would be helpful if you explained more detail about the project
 

Thread Starter

dbrckovi

Joined Sep 3, 2018
17
That is the same conclusion I got to in the last 4-5 posts.
The question is already answered.
I wasn't aware that OpAmps have minimum input voltage and your LTSpice charts showed that.
Thank you.

I will connect the Vcc- to -5V and that should bring the input into OpAmps operating range.
If not, I will experiment further.
 

ericgibbs

Joined Jan 29, 2010
18,766
hi,
OK,
If the Arduino ADC Vref is set to say 5V, thats 1023 max counts, so try to increase the input to much greater than 22mV.
An ADC in of 22mV is (0.022/5) *1023 = ~ 5 counts.!

Post your new circuit when ready and we can run it in simulation,

E

EDIT:
This image shows one option, its not elegant.
 

Attachments

Top