uCurrent mA range error using oscilloscope and function generator - Page 1
Forum section: electronics / projects

author: luisprata
author_rank: Regular Contributor
timestamp: April 23, 2017, 05:18:43 pm
content: Hi Folks,I'm using internal function generator of my keysight oscilloscope to generate a 20mA sine current and trying to see it on scope using microcurrent.Instead of 20mV as result I've got 66mV. AC or DC are the same. Why?At this configuration I´ve noticed that about 0,5mA current are passing through +Input to -Output.Effect of small sense resistor and pcb tracks resistance, maybe?Anyway, I figure out its better not to use the output negative born. Just connect both grounds into input negative terminal.See the video. What do you think? Am I doing something wrong? Please, comment.Thank you.

author: joeqsmith
author_rank: Super Contributor
timestamp: April 23, 2017, 07:41:44 pm
content: I do not have one of Dave's uCurrent Golds to test but I tried to set up a similar test and attempt to walk you through it. At least with my setup things appear as I would expect them to be.https://www.youtube.com/watch?v=SHGlz_wpZ1o&feature=youtu.be

author: FrankBuss
author_rank: Unknown
timestamp: April 23, 2017, 09:02:01 pm
content: I don't know why it should be different where to connect the ground, because I measured the connection between the two ground connectors and it is near 0 ohm, so should be no difference, right?But I tried your setup: The function generator of my DSO-X 3012A generated a frequency of 120 Hz and an amplitude of 3.03 Vpp, which is 1.071 V RMS. The output of the function generator goes into my BM257s DMM, measuring the current in mA mode, and from this it goes into the uCurrent in mA mode and the ground output of the uCurrent Gold is connected to the ground of the signal generator of my scope. The DMM and the uCurrent combined have less than 3 ohm of shunt resistors. Together with the internal 50 ohm output resistance of the function generator, this results in 1.071 V RMS / 53 ohm = 20 mA RMS, which my DMM shows. But at the output of the uCurrent I can measure this (same scope) :So this is 28.4 mV RMS, very wrong. But if I connect the ground lead of the scope to the input ground of the uCurrent, the scope shows this, pretty close to what my DMM shows:Not as much wrong as your result, but still, 30% error is not nice. Maybe Dave or someone other can reproduce this and explain it?The uCurrent is unmodified, this means I removed the 100 nF input capacitor, which I use for DC measurements for the nA range, but I think this is a different problem than the feedback problem I had in the nA range.

author: luisprata
author_rank: Regular Contributor
timestamp: April 23, 2017, 09:02:16 pm
content: Hi Joe,Thank you for your post .And what about your layout ?Once both ground are the same, part of signal could return using oscilloscope ground instead of generator ground, couldn't?In this case, some current pass through +input to -output. Depending on the layout it can affect measurement or not, am i right ?What do you think?Thank you again.

author: luisprata
author_rank: Regular Contributor
timestamp: April 23, 2017, 09:12:44 pm
content: Hi Frank,Its Good to know that you got similars results.I think it could be something related to layout. Once both ground are the same, part of signal could flow through +input to -input and a small part could flow through +input to -output (-output, -input are both grounds). This small current passing through the circuit may generate erros I don't know how.Thank you.

author: luisprata
author_rank: Regular Contributor
timestamp: April 23, 2017, 09:20:33 pm
content: Its possible?

author: FrankBuss
author_rank: Unknown
timestamp: April 23, 2017, 09:33:48 pm
content: Quote from: joeqsmith on April 23, 2017, 07:41:44 pmYour version of the amplifier looks nice, the additional protection with the fuse and diodes is a good idea, this is missing in the uCurrent. And looks like it doesn't have the problem reported in this thread. Do you plan to sell this? If not, I could create a KiCad circuit for it, so that everyone can build it. Which OpAmp do you use? And why do you use a coaxial output?PS: I don't think using a simple resistor voltage divider is a good idea for the virtual ground. The uCurrent uses another OpAmp for it, which of course is a cheaper one than the chopper OpAmp.

author: joeqsmith
author_rank: Super Contributor
timestamp: April 23, 2017, 10:51:20 pm
content: Quote from: luisprata on April 23, 2017, 09:02:16 pmLayout? I have no layout.My two grounds are not the same. The output is at the 0.01 ohms sense which is not the same is the input ground (its a 4-wire shunt). My guess is this is not your problem but something much more simple.I suspect your AC power has setup a ground loop that you have not considered is all. In my case I know the LeCroy's input ground is tied to the earth ground of the AC. This could cause a problem but I know my particular signal generator is floating. So, no loop. If it were not floating, I would have had to isolate it to break that path. You need to consider both the AC and DC paths.

author: joeqsmith
author_rank: Super Contributor
timestamp: April 23, 2017, 11:02:29 pm
content: Quote from: FrankBuss on April 23, 2017, 09:33:48 pmIt was tossed together yesterday morning for a demonstration. No, I have no plans to try and sell it or create PCBs for it. I use the BNC because I had one in the junk drawer. I mentioned the op-amp in the video above. Full video is below.

author: luisprata
author_rank: Regular Contributor
timestamp: April 24, 2017, 12:18:33 am
content: Quote from: joeqsmith on April 23, 2017, 10:51:20 pmkkkk. Ok, no layout.I didn't understand when you say your meter has different grounds. Doesn't the input ground connect to output ground? 4-wire shunts have 2 terminals at both endings but they are the same, right? Did I miss something in your sch?The problem I mentioned will not happen in isolated systems. I know battery powered devices are tipical applications to use ucurrent but I think it could be used in earth grounded systems (only in low side sensing). Can´t it? Could you test with your function generator grounded?I'm thinking about ground loop. Ground loop is clearly stablished in both two setups, good and bad. So, I think its not the culprit in this case.I hope I'm not bothering with my questions but I really would like to understand what's going onThank you.

author: joeqsmith
author_rank: Super Contributor
timestamp: April 24, 2017, 12:47:37 am
content: I watched a few of your videos. You have very good English.Quote from: luisprata on April 24, 2017, 12:18:33 amRight, that amplified shunt circuit was a throw together with little thought to anything beyond getting it put together. I did paint the box if that counts for anything which is why it was not in the box when I made this little video for you.I'm sure Dave's product would provide much more accurate results. Just the fact he used much tighter tolerance parts is a big step. It will be interesting to see what he has in the 121GW once it is released.Quote from: luisprata on April 24, 2017, 12:18:33 amNo not right. There are 4 wires and yes two sets on each side. The one set carries the current, the other does not. If it does, you have a problem.Quote from: luisprata on April 24, 2017, 12:18:33 amAs long as you consider all of the paths, sure you can do most anything as long as you don't try and break the laws of physics.Quote from: luisprata on April 24, 2017, 12:18:33 amRight, from previous comment, my signal generator is isolated. DC wise its a meg. At 120Hz, no problem. That 1Meg will cause some error but nothing I am concerned with at these current levels.Quote from: luisprata on April 24, 2017, 12:18:33 amNo problem, just make sure you understand all the paths the current can flow and guard against them and you will be fine. Good luck.

author: amspire
author_rank: Super Contributor
timestamp: April 24, 2017, 01:29:19 am
content: The very first thing I would check is if the Keysight oscilloscope has a true 50 ohm output, or just an output that is calibrated for a 50 ohm load. If you set the output to 1V p-p and check it with just the x10 probe, do you get 2Vp-p output?If you put a 10 ohm resistor across the 50 ohm output, does it drop to 0.333 volts p-p?Definitely check the Keysight output behaviour before worrying about the uCurrent readings.

author: luisprata
author_rank: Regular Contributor
timestamp: April 24, 2017, 02:23:29 am
content: Quote from: amspire on April 24, 2017, 01:29:19 amKeysight wavegen output is 50 ohm. If I put a resistor in series I got the expected 50 ohm voltage divider value.Just out of curiosity, in wave gen you can set "output load" to high-z or 50 Ohms. Nothing actually changes. Its only to inform wave gen you are using external termination and then wave gen will divide by 2 the amplitude value.

author: Teuobk
author_rank: Contributor
timestamp: April 24, 2017, 02:30:47 am
content: I thought, "They must be doing something wrong with their measurement setup," so I gave it a go with a uCurrent Gold. Much to my surprise, I got the same results.A few notes:1. This happens even with a differential probe at the output2. This happens even at DC with an isolated supply.3. This happens even by simply shorting the negative output terminal to the negative input terminal; connecting the negative output terminal via a separate path to a low-impedance ground is not necessary4. Careful measurements with a DMM placed on the high side and the low sides of the path back to the signal generator confirms that the true current remains steady on both the high and low sides regardless of whether the two negative terminals on the uC Gold are shorted. (This measurement required a differential probe on the uC Gold output, obviously)5. This does not happen if the short between the two uC Au negative terminals is switched to even a 1 ohm resistor6. The lead I was using for a short had a measured resistance of 10 mohm. Frequency was 95 Hz, amplitude was 1 Vrms, load was 10 ohms in parallel with the uC gold.7. This does not happen on the other uC Gold ranges; amplification is the expected 100:1.8. This is probably not related to the bias current on the first-stage uC Gold op-amp, since those are CMOS inputs with bias currents in the picoamp range.9. Shorting the two negative terminals also introduces a small DC offset to the output, which suggests that the issue is somehow related to the virtual ground.10. With the two negative terminals "shorted" with the 10 mohm-resistance lead, and differential probes on the output, the potential difference between the negative output terminal and the negative input terminal is about -500 nV; i.e., a few microamps of current is flowing out of the negative output terminal towards the negative input terminal. (Or so I think. This is right down near the limit of what I can measure reliably, and I don't have a meter with a small enough sense resistor at the microamp range to measure the current directly.)I've considered a number of explanations, but none of them have held up to experimental measurement with an actual uCurrent Gold in the system.I suspect this is somehow related to the trace resistance, but again, nothing I've worked through has stood up to experimental evidence.No solutions, just some observations.

author: EEVblog
author_rank: Unknown
timestamp: April 25, 2017, 10:39:55 am
content: I have not verified this, but yes I think it's possible because likely:a) The uCurrent was never designed to pass ground current through to the output, it was always assumed the output would be isolated with regards to the input. When you start getting system ground currents (leakage or otherwise) between source and the output device then you are asking for trouble.b) There are layout limitations caused by the single single sided PCB front panel layout that may be causing this.It needs more investigation

author: FrankBuss
author_rank: Unknown
timestamp: April 25, 2017, 01:33:14 pm
content: Quote from: EEVblog on April 25, 2017, 10:39:55 amI tested it with AC only, but Teuobk wrote that this happens even for DC with an isolated supply, so I guess this could not be the reason for this problem, because then there is no current flowing from input to output.PS: Do you have a manual for analog noobs like me how to use the uCurrent the right way? I ran into another problem, but I could explain and solve this one:https://www.eevblog.com/forum/testgear/problem-with-ucurrent-gold/

author: luisprata
author_rank: Regular Contributor
timestamp: April 25, 2017, 01:59:37 pm
content: Thank you Dave.I know it's an out of spec usage, but more and more oscilloscopes are coming with internal function generator.It could be useful and didactic to know how to test uCurrent properly with them.I'm very satisfied with my ucurrent exactly as is. But for learning purpose , can I put a 270R resistor between R1 and and virtual ground like in positive side of this sensor?Thank you.PS: I'm a Brazilian EEVBlog fan !

author: luisprata
author_rank: Regular Contributor
timestamp: April 25, 2017, 02:22:21 pm
content: Frank,May be our problems are related.Updated:Probably not.I think in nA range touching is really a problem.Why the problem comes up when you touch only positive terminals?Hipotesis: ucurrent ground is stronger earth coupled than positive signals due to ground plane in pcb. So when you touch positive terminals current flows to negative. When you touch negative ones current flow to earth.

author: FrankBuss
author_rank: Unknown
timestamp: April 25, 2017, 02:52:02 pm
content: Quote from: luisprata on April 25, 2017, 02:22:21 pmI don't think that they are related, because the nA problem was a feedback problem, which is understandable for this low range. But I don't understand the problem for the mA range, should be much less sensitive to all kind of problems, like ground loops.

author: luisprata
author_rank: Regular Contributor
timestamp: April 25, 2017, 03:23:23 pm
content: Take a look at my post again. I've updated.

author: FrankBuss
author_rank: Unknown
timestamp: April 25, 2017, 03:27:33 pm
content: I have no idea, I don't know much about analog stuff, but I'm sure Dave will sort it out

author: luisprata
author_rank: Regular Contributor
timestamp: April 25, 2017, 04:11:46 pm
content: Frank,I'll try to replicate your setup here.Just out of curiosity, what happens if you connect a square metal piece (or a bare pcb) simulating a ground plane in negative terminal of your reference setup (only multimeter, resistor and batt) and then you touch positive ?

author: amspire
author_rank: Super Contributor
timestamp: April 26, 2017, 03:34:03 am
content: If it is a voltage between the input uCurrent negative and the output negative, then if you used the oscilloscope in differential mode (A-B), with the scope grounds on the input earth and the A and B probes on the two output channels, you should get the expected reading. With the way it is being used here, the resistance of the connection from the current sense resistor and the negative terminal does cause an error.It is only designed to be accurate if you are measuring the actual voltage between the output connectors. It is usually used with multimeters or desktop DVM's that both are floating with respect to ground.It is also a good idea to short the 50 ohm generator output, and put a scope probe on the generator output ground to see if there is a difference between the scope ground and the probe ground.As a next generation uCurrent, it could be worth looking at a fully isolated input, so it can be used with scopes. Then again, if you are interested in the AC current, it is hard to beat a current transformer.

author: luisprata
author_rank: Regular Contributor
timestamp: April 26, 2017, 05:16:21 am
content: Quote from: amspire on April 26, 2017, 03:34:03 amYou're right. Considering 1/2" 15mils pcb track resistance of 0,03ohm and 20mA current = 0,6mV (3% error)Quote from: amspire on April 26, 2017, 03:34:03 amWell, my generator is built-in the oscilloscope, so grounds are the same. The cable and probe lengths, and resistances, are not equal so we have a current divider between (- input) and (-output).Maybe a better solution will be putting a 270 ohms resistor between R1 and vGND, just like in R1 to +op amp connection. This way only a negligible current will circulate. But I'm not sure if it will affect the opamp.Using both grounds at (-input) is not a too bad solution considering no modifications are required.More tests needed.