6
\$\begingroup\$

I've gone back to my constant current project to fix an annoying fluctuation in the required current display. See schematics below.

The entire circuit consists of a CCS section with signal outs for both the requested current (represented by Vreq) and the actual current (represented by Vact developed across the sense R).

These signals are sent to an amplifier which scales them up x10 and the amplified signals are sent to a uP ADC with an external 2.5V ADC reference.

I'm using a star-ground approach and I keep digital (uP, display driver) and analogue (CCS, amplifier) grounds separate, with a separate ground point for the load return.

Despite this, the required current selected by the 100k POT moves up and down a mA or two on the display. In preparation for some low-pass filtering, I took some readings with my oscilloscope probe (set to x10) and to my astonishment, the display was rock solid. No fluctuation, perfectly smooth with the POT turns.

It didn't matter which "Probed" point I tried (see diagrams below), the effect was the same. Realizing that the probe contains some capacitance and a large resistance, I tried placing a 22pF and 10M in parallel at one of the points probed. So, far I haven't managed to replicate the "fix" brought about by the probe. I'll get a chance to do some more this evening, but in the meantime: can anyone tell me why the probe has had such a "beneficial" effect on my circuit?

Thanks!

UPDATE: I should have pointed out that the oscilloscope is mains connected and its ground lead is connected to earth ground. Also, the circuit itself is floating, that is it's connected to a 5V wall regulator that doesn't use earth ground. One other thing, in all cases when I probed the circuit ("probed" points), I connected the oscilloscope earth lead to the local ground at that point (not the star ground point) - not sure if that makes any difference.

While I'm updating, another intriguing thing is that if I attach a load (say a 100 ohm resistor) the readings seem to be quite stable. Not sure if this is related, but I thought it was worth mentioning.

ANOTHER UPDATE:

Well, I had a chance to test things a bit further. Seems like it's the connection to earth ground that fixes the issue, so @WhatRoughBeast is on the right track. Unfortunately, the twisted pair trick didn't work.

FINAL UPDATE:

I finally got the circuit to work reasonably well. I changed the 100k multi-turn pot for a 10k (and the 1M5 resistance to 150k) and the increase in current seemed to cure the flickering, except when the pot resistance was quite high. I also shortened the signal wires and implemented a simple digital low-pass. If I had this to do again, I'd use a proper PCB with a ground plane.

enter image description here enter image description here enter image description here

\$\endgroup\$
  • 1
    \$\begingroup\$ Is your scope powered from mains and if so, does it have an earthing contact? \$\endgroup\$ – Peter Smith Feb 2 '16 at 13:02
  • \$\begingroup\$ Yes it is and yes it does. I'll update the question with this detail. \$\endgroup\$ – Buck8pe Feb 2 '16 at 13:30
  • \$\begingroup\$ Most probes look like a 10M to 1M divider with the capacitance modeled as 20pF to GND in parallel with the 1M resistor. This is because this is where the input goes into the preamp before the adc. It is possible that this simple GND path is helping to stabilize the output of the opamp because you might be operating at a harmonic due to the RC feedback in the opamp. to test, put a 10M resistor to GND on the test point or play with the frequency of the opamp. \$\endgroup\$ – b degnan Feb 2 '16 at 13:55
  • \$\begingroup\$ With you up to this point: "operating at a harmonic due to the RC feedback in the opamp". RC feedback owing to the probe? \$\endgroup\$ – Buck8pe Feb 2 '16 at 14:00
  • \$\begingroup\$ Note that the circuit will only be truly floating if the wallwart is transformer coupled; there can still be an effective return via the neutral side. \$\endgroup\$ – Peter Smith Feb 2 '16 at 14:20
4
\$\begingroup\$

This may sound odd, but I suspect it is your grounding philosophy which is getting you in trouble. Star grounding is the standard approach for power wiring in order to avoid ground loops. It is not appropriate (usually) for signal circuits. The problem is that, for high impedances and long(ish) wires, it invites the formation of large-area ground/circuit loops, which will respond to varying magnetic fields by acting as antennas and injecting noise into the signal path.

Try connecting your Vact to the A/D input via a twisted pair, with the other wire connected to ground at both ends. Yes, this will produce a ground loop, but with very low currents the imposed noise should be very small and dominated by the reduced pickup on the microphone signal.

If that doesn't work, try disconnecting the twisted pair's ground wire at the A/D side, but leave it connected at the sensor side.

EDIT - Looking further at your circuit, there are a number of issues. If this is all there is, you are getting yourself in trouble with your grounding philosophy. Unless there are other loads involved, what you are doing is simply not worth a star ground. Your CCS only produces a maximum current of about .6 amps, assuming your 1k load resistor is an error. This is not an enormous current level.

You have not described your circuit partitioning, but if all 3 circuits are part of the same PCB, then you should simply use a single ground plane for all grounds. The low resistance produced by the ground plane will overwhelm any other effects. As a further tip, place the ground power connection close to the bottom of the sense resistor.

If the first section is physically removed from the other two, and you are uncertain of coupling via twisted pair, the standard approach is to use a difference/instrumentation amplifier

schematic

simulate this circuit – Schematic created using CircuitLab

Use twisted pair for the connection from the sensor. C2 and C3 should be ceramics. They filter out any pickup around the loop produced by the separation of the grounds. The op amp responds to the difference between the two sensor points, and since it draws virtually no current in its inputs, it rejects the effects of any current flow between the two ground points.

Twisted pair acts as a poor man's shield. The ground wire acts to intercept radiated energy, and because it is in close proximity to the signal wire it tends to shield it. For really high-sensitivity applications, you use coaxial cable, which has an inner conductor completely surrounded by wire mesh or metal foil.

\$\endgroup\$
  • \$\begingroup\$ I'm guessing the idea behind the twisted pair is to reduce noise in the signal carrying line, but I'm struggling to see how exactly. Can you expand a little bit on the theory behind that? \$\endgroup\$ – Buck8pe Feb 2 '16 at 14:06
  • \$\begingroup\$ Also, regarding the start grounding. I realized early on in this project that the load ground (which can carry high currents) can impose quite a bit of ground loading and affect the accuracy of the other sections. That's mainly the reason why I opted for the star setup. \$\endgroup\$ – Buck8pe Feb 2 '16 at 14:09
  • \$\begingroup\$ @Buck8pe - See edit. \$\endgroup\$ – WhatRoughBeast Feb 2 '16 at 15:07
  • \$\begingroup\$ Thanks for the effort, I understand how the twisted pair works now. This is very much a hobby project, built in sections on stripboard. Rload is intended to be a "circuit under test", with the whole point of this device to provide short circuit protection. Still, it's been a great learning exercise - as these things should be, I suppose. I'll try your suggestions and let you know how I get on. \$\endgroup\$ – Buck8pe Feb 2 '16 at 16:16
  • \$\begingroup\$ @Buck8pe - I'd be very careful about drawing 0.6 amps on stripboard. \$\endgroup\$ – WhatRoughBeast Feb 2 '16 at 16:59
1
\$\begingroup\$

I'm quite confident that using a Zener Diode for the 2.5V voltage reference isn't enough precise for an ADC, even more if you have grounding problems as you figured out by probing the circuit. I always use a voltage reference IC when connecting an ADC, i.e. AD780 : http://www.analog.com/media/en/technical-documentation/data-sheets/AD780.pdf

\$\endgroup\$
  • \$\begingroup\$ That's a fair point, and I've made some allowances in software for a certain lack of tolerance in some components (like the reference being 2.49V and the opamp resistor network delivering a gain slightly over 10). But, when the scope probe is attached, the reading is pretty accurate. \$\endgroup\$ – Buck8pe Feb 2 '16 at 14:37
  • \$\begingroup\$ After reading your post, it seems that the problem is coming from your 5V power being floating. When you attach a load to the circuit, you make a path to the ground, therefore the +5V is no more floating. I don't understand why you are using this configuration for VCC. \$\endgroup\$ – lucas92 Feb 2 '16 at 14:49
  • \$\begingroup\$ Some confusion here I think. The load is in actuality some circuit under test. I use this device to protect early test circuits from damaging currents, in the event of shorts. All voltage is provided by the 5V supply, all ground current returns to the same supply. Where you see Rload in the first schematic is where the circuit under test sits. \$\endgroup\$ – Buck8pe Feb 2 '16 at 14:56

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.