Maker Pro
Maker Pro

Comparator inputs

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
Thanks Duke. Yes that's true. The trouble with putting a potentiometer from the comparator's output to its non-inverting input is that the amount of hysteresis would not be directly proportional to the potentiometer position, and it would be impossible to remove the hysteresis completely.

The way I have it now, the hysteresis adjustment doesn't move the thresholds further away from a centre voltage that's set by the "favour" pot; one of the thresholds is fixed by the "favour" pot position (roughly) and the hysteresis control moves the other threshold away from it. Which arrangement has more interaction between the two controls depends on how you look at it, I guess.

What do you think?
 

EinarA

Feb 11, 2013
28
Joined
Feb 11, 2013
Messages
28
Kris, I know I'm somewhat biased, but I'll try to be objective. In fact I've never used current transformer myself which is one reason I didn't use Duke's connection; I definitely don't have good feel for how a real transformer will behave. Since a 393 can sense at ground there isn't a good reason to bias at half supply. I think it is much easier to select two matched resistors than trim out an offset. You can create bipolar hysteresis by slightly offsetting the input and making the feedback switch by an equal amount around this nominal zero point. It is much easier for me to see how my circuit will behave, but you probably find yours easier; it's more a matter of style.
In my schematic I forget to say that the diodes are schotky or Ge types which have less than .25 drop at low current. For Viad's use this would be a low enough power situation that having the circuit treat them as equal would be OK.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
EinarA, thanks for your comments.

The reason for biasing the inputs is that the offset adjustment may need to be quite large; it's not to compensate for error, it's because Viad wants to be able to favour one phase over the other. This requirement emerged somehow in the early part of the thread, before I posted my first attempt at a design, because that first design included that feature.

I wasn't sure if this would be better done by scaling one current value (e.g. by using a variable shunt resistance) or by comparing them using a variable offset. I went for the latter because it will be effective even when both currents are very low or zero. It makes the "favour" adjustment an absolute amount of current, rather than proportional to the actual current, which I think is more appropriate.

Thanks again for your feedback :)
 

EinarA

Feb 11, 2013
28
Joined
Feb 11, 2013
Messages
28
I understand what you were going for and didn't want to say that your circuit is wrong; it's just not ideal. Your way of creating a variable offset sets up a bridge circuit and the trim pot has to null out the mismatch of the four resistors as well as create the desired offset. This resistor error is the offset I was referring to. If you create a pseudo ground it's best to reference all the other parts of the circuit to it. Ideally the fovour pot should have a zero point you can turn it to. If you look at my circuit you will see that the voltage on R3 , and the plus input, is always positive, meaning input 1 has to be greater than input 2 to make the comp switch on. So the circuit favors input 2. Varing R4 will alter the amount of favouritism, although not in very linear manner. Changing R5 will alter the amount of hysteresis. This circuit can't create an un- favored situation except by offsetting the input slightly by connecting a very large valued resistor to V+.
I drew up the circuit below to show an 'unbiased' arrangement; the trip points are equidistant from the zero point and the error in R1 and R2 has only a trivial effect. The input circuitry is lumped into the Vin symbol. Typical resistor values would be 1K for R1,2; 100K for R3; and 1M for R4. Changing R3 will change the trip points in a nicely linear manner. Replacing R1,2 with a trim pot will allow a degree of favoritism without significantly changing the amount of hysteresis; as Vb is moved away from the center point the center of hysteresis band will be similarly shifted.
I admit that your circuit covers all the possibilities in one go, it can be hard to set up though. I don't really claim that either of my two ideas are ' better', and I don't immediately see an ideal circuit. Perhaps you can.
 

Attachments

  • image.jpg
    image.jpg
    34.8 KB · Views: 163

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
EinarA, thanks for that thorough response. I'm trying to understand it (it's Friday night so it might take a while :) One thing I noticed: you said the "favor" control should have a zero point; if it should, it would be mid-way because either phase needs to be able to be favored. That's how I intended the control to work, based on what I understood from the OP's explanation. The whole circuit is supposed to treat both positive and negative differences (after offsetting by the favor adjustment, which maps linearly to measured differential, in amps, averaged by RF and CF) with equal importance. At least that was what I intended. I'll try to absorb your comments later!
 

EinarA

Feb 11, 2013
28
Joined
Feb 11, 2013
Messages
28
I missed that you wanted to favour either " phase". Now I see why you chose that circuit. In mine I made it favor input 2 , the user would chose which load this was when he wired it up.
As I understand it the two transformers are measuring two load circuits and our circuit switches two power sources. Since one is a wind generator the two sources may not be freq/phase locked and Duke's series connection will cause a beat frequency of a few hertz or less that will be almost impossible to filter out. If Viad ever comes back hopefully he can answer this.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
Ah. I hadn't thought of that. You're right. My series connection of the unsmoothed signals would cause a problem if the CTs are monitoring currents from different sources. The solution would be to smooth them independently before subtracting one from the other. That's probably what Duke intended.

As for the circuit being able to favour either current, yes, that was my intention, but Viad didn't ask for that, and I don't think there's any need for it. I just did it that way because I liked the idea of a symmetrical design.

Edit: The part I do think should be symmetrical is the handling of the two measurements after the favouring offset has been applied. The delay for switching from A to B should be the same as for the other direction.
 
Last edited:

Viad

Feb 9, 2012
29
Joined
Feb 9, 2012
Messages
29
Kris, back again with a question, however I see there have been several posts since I last posted ( I didn't receive any notification of them ?)
Re your second circuit , it worked eventually.
Lessons learned
Don't use cheap Chinese bread boards
Dont use cuttings of telephone cable as links
Layout the components on the bread board as similar to circuit diagram as possible

Ok it worked but the 270 ohm burden resistors were producing to great a voltage gain.
I replaced them with a 47 ohm and 22 ohm . This brought the voltage output down to useful levels
2.1 A through CT (a good minimum starting point) into 47 ohm burden gave 150 mV Pk Pk !/P 10 measured 0.7 v on AVO and I/P 9 measured 9.65 v

My question is what effect will altering the burden resistor have, I have taken lots of measurements but it seems that the response is not linear since swapping the 270 ohm resistors to the lower value
I have two different sized burden resistors to give the two different rates as described in earlier post
I'm not sure if your 'favour' circuit was meant to achieve this , but it wouldn't as it just offsets input 1 either side of input 2 by a small percentage .
I shall now go and study more closely the new posts, thanks to all
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
The CT output voltage for a given CT input current should definitely be proportional to the burden/shunt resistor value. Halving the shunt resistor value should halve the voltage you measure, for the same measured current.

BTW the favouring circuit offsets the measured currents against each other by an adjustable amount, which corresponds to a fixed number of amps, not a percentage of any measured value.

If you're not seeing updates on threads that you've posted on, you may need to change a setting on your account.

1. Click User CP (on the menu bar under green Electronics Point logo).
2. Under Settings & Options on the left, click Edit Options.
3. Under Messaging & Notification, in Default Thread Subscription Mode, change the selection box to "Instant email notification" (or Daily or Weekly if you prefer).
 

Viad

Feb 9, 2012
29
Joined
Feb 9, 2012
Messages
29
Thanks Kris and Einar A
I have described the set up in an earlier post but basically there is only one power source. In fact it is irrelevant what the power source is .
The single power source AC can be fed to one of two separate loads.
I want to monitor the two separate loads using two CTs.
The circuit will switch a contactor to feed the power source to whichever circuit is drawing the most current.
The monitoring range will be ok from around 2 A up to around 25 A above 25 A it doesn't really matter which load the power is sent to.
One input is required to be half as sensitive as the other.
hope that helps
thanks
 

Viad

Feb 9, 2012
29
Joined
Feb 9, 2012
Messages
29
I have constructed EinarA's circuit and results are promising although I have not as yet tried it out at the full range of currents.
Can you explain the purpose of the two Schottky diodes grounded and connected to the R1/R2 junction ?
Is C3 a 0.1 mfd ?
Is it the 1M resistor connected to C3 that you suggest changing to 330K ?
Is it ok to change R1 and R2 to much lower values , for example 160 ohm and 80 ohm
this will also give me the 1:2 ratio I require ?
thanks.
A day later... Wanting to monitor the outputs from the CT's , but the waveform across the CTs Pk Pk is really distorted, making it difficult to measure and decide what effect the inputs are having through the circuit 'if that makes sense'
 
Last edited:

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
Have you looked at the CT secondary waveform with just the shunt resistor connected to it? Can you post a photo of the waveform?

What type of loads are you powering? Unless they're resistive (e.g. heating loads), the current waveform will not be a nice sinewave.

BTW if you use EinarA's circuit you may want to fix the voltage thresholds for the final Schmitt trigger so the delay capacitor gives the same delay for switching from A to B as for B to A. The values in my most recent post will do this (thresholds are at about 1/3 and 2/3 VCC, i.e. equally balanced around VCC/2). You might want to add a resistor across the LED as well so that the comparator output is pulled all the way up to VCC.
 

Viad

Feb 9, 2012
29
Joined
Feb 9, 2012
Messages
29
Hi Kris , the loads are tungsten lamps for trial purposes, there is something in the circuit causing one half of the sinewave at each input to elongate in a fainter fuzzy half wave. I will try a photo if need be. I will try it with just the circuits two shunt resistors. Do the need to be such a high resistance ?
I am going to try your circuit soon Kris, the full wave rectification will entail two diode v drops though, would an op amp rectifier be better.

My own earlier attempts worked to a degree, but as I recall using a burden resistor to give a usable output at low currents meant that the output overloaded the circuit at high currents. I wondered at the time what sort of circuit could reduce the output as it increased --- but that's a whole new story, I know.
thanks meantime
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
OK. This business about the shunt resistor values being wrong seems odd. You know the current ratio of the CTs, and you know Ohm's Law, so you know what values should be needed. The calculations I used to work out a value of 270 ohms are in post #19 on this thread.

A "fuzzy" appearance on an oscilloscope can be caused by different cycles being different. When all the different cycles overlay each other on the scope, the matching parts overlap and look clean, but the non-matching parts give a fuzzy effect. Slowing down the scan rate can make this clearer.

It could also be some kind of oscillation in the circuitry.

Beyond that, I can't suggest anything. I've never used CTs before and I know very little about them.

Full-wave rectification shouldn't be a problem because the shunt resistor is after the rectifier. The CT's output is a current, and it should have a wide compliance voltage range. In other words, it can generate plenty of voltage, so the voltage drops can be ignored; it's only the output current that's important, and this is converted to a voltage by the shunt resistor which is after the rectifier.

The shunt resistors should be chosen so that the shunt voltages are within the circuit's supply voltage at the currents of interest. If one or both currents go much higher than that, the difference voltage will be limited because the 330k resistor in the smoothing circuit cannot supply much current. A couple of diodes would be appropriate to protect the comparator's input on pin 2 though.

BTW, CS1 and CS2 in the diagram in my post #39 on this thread aren't needed; they won't have any effect. You might as well remove them.
 
Top