Delay a relay after startup

Thread Starter

andrew74

Joined Jul 25, 2022
224
Hi again,

Well if we define the 'inrush' current as a current that increases very fast but then after a somewhat sort time it decreases to some normal level, then we want to detect the higher current and then after a delay (where we assume the current has then decreased) turn the relay on to short out the limiter component (resistor or thermistor). That might help to think about this clearly.

What this means is that the comparator will be set at some level with a voltage reference (like a zener) and when the voltage gets over that value it starts the delay countdown. The voltage is of course developed from across the limiting resistor or thermistor, or perhaps a second resistor just to sense current.

If the output of the comparator is normally 0 volts, then when the current shoots up the voltage across it shoots up, and the comparator output goes from 0 volts to say 5 volts and that starts the delay. After the delay period, the relay coil turns on and a second set of contacts bypasses the delay and comparator and keeps the relay turned on.
This means the comparator needs to have enough built in hysteresis to keep the relay energized for enough time so the relay contacts actually close, or that alone keeps the relay turned on.

Just for example, let's say we are using a 1 Ohm sense resistor which also limits the current, and say the normal current is 1 amp and the surge is 2 amps. That develops 1 volt and 2 volts respectively.
If the comparator is set for 1.6 volts (detecting 1.6 amps) then when the current goes to 2 amps that trips the comparator and the output goes to +5v thus initiating the turn on of the relay. Now say the current drops to 1 amp, then the relay contacts actually close. The comparator lower limit would be set to say 0.5 amps, and so it will remain with the output at +5 volts. Only when the system is shut off will the comparator and thus the relay be reset to the starting state.
So in this example we set the upper limit of the comparator to 1.6 volts and lower limit to 0.5 volts. We can look at the formulas for those settings. It involves the usual comparator connections plus an extra resistor from the output of the comparator to the non-inverting input of the comparator, which will also have other resistors connected to it.

The calculation for the hysteresis resistor value is not that difficult. When you come up with the basic circuit you can post that and then we'll look at calculating that resistor value.
What about something like this?
Is this the correct path to follow?
SmartSelect_20251007_205403_Samsung Notes.png
1. 60A spike arrives in red
2. 10 ohm NTC limit it to 6A on horizontal line because relay is still open
3. Relay closes and input signal will follow purple path, bypassing NTC

I don't know if I have made myself clear, but the relay must remain closed forever after NTC has done its work. It seems to me that in this circuit the closure of the relay given by the comparator lasts a "limited" period of time before the comparator reopens (?)
 

MrAl

Joined Jun 17, 2014
13,704
What about something like this?
Is this the correct path to follow?
View attachment 356872
1. 60A spike arrives in red
2. 10 ohm NTC limit it to 6A on horizontal line because relay is still open
3. Relay closes and input signal will follow purple path, bypassing NTC

I don't know if I have made myself clear, but the relay must remain closed forever after NTC has done its work. It seems to me that in this circuit the closure of the relay given by the comparator lasts a "limited" period of time before the comparator reopens (?)
Hi,

Yes that's approximately what the circuit might look like, but as noted previously, there has to be some built in hysteresis. That's what R3 is for in the modified circuit attached. There also probably has to be a pullup resistor R4 unless the comparator type does not need that.

Also note the added ground indicated with the large red arrow. That means the 12vdc line most likely has to be galvanically isolated from the main voltage which means a transformer possibly just a wall wart.

Take a look and we can discuss this further. The values of the resistors will fall into place once we get everything else nailed down. We also have to know the relay coil current you'll have to specify that as the added transistor type will depend on that.
Also note the added diode across the relay coil. A type like 1N4004 would be good enough.
There's an added zener too Z2. That's to protect the comparator when a surge occurs.

There is a bit of a catch or two here.
1. We see the thermistor labeled as "10 Ohms", is that cold resistance or hot resistance, and what is the difference between the two resistances hot and cold?
2. You should note that some loads will not start properly with a resistance in line which means the surge could last longer, but with 10 Ohms in series the max current will probably only be able to get to around 5 amps, if that's the cold resistance.
 

Attachments

Thread Starter

andrew74

Joined Jul 25, 2022
224
Hi,

Yes that's approximately what the circuit might look like, but as noted previously, there has to be some built in hysteresis. That's what R3 is for in the modified circuit attached. There also probably has to be a pullup resistor R4 unless the comparator type does not need that.

Also note the added ground indicated with the large red arrow. That means the 12vdc line most likely has to be galvanically isolated from the main voltage which means a transformer possibly just a wall wart.

Take a look and we can discuss this further. The values of the resistors will fall into place once we get everything else nailed down. We also have to know the relay coil current you'll have to specify that as the added transistor type will depend on that.
Also note the added diode across the relay coil. A type like 1N4004 would be good enough.
There's an added zener too Z2. That's to protect the comparator when a surge occurs.

There is a bit of a catch or two here.
1. We see the thermistor labeled as "10 Ohms", is that cold resistance or hot resistance, and what is the difference between the two resistances hot and cold?
2. You should note that some loads will not start properly with a resistance in line which means the surge could last longer, but with 10 Ohms in series the max current will probably only be able to get to around 5 amps, if that's the cold resistance.
Thank you for the detailed answer!
Some questions:

1. 10 ohms is the cold resistance. I don't know the hot resistance because I didn't choose the NTC, so I don't have an R-T curve. Why should I know the hot resistance of the NTC? To dimension what?

2. I didn't know about this load thing with a resistor in series at startup .. can you give me an example of what kind of load can have problems? And how? I don't understand this...

3. I assume the voltage Vz2 is greater than Vi, right? A little less than the maximum V the comparator can receive at its input

4. R4 required because comparator has open collector output, right?

5. OK about galvanically isolating 12V from Vi ... but I don't understand two things:
- isn't an isolated DC-DC sufficient?
- I don't understand why you put ground there in the red arrow, you are connecting Vi to GND
 

MrAl

Joined Jun 17, 2014
13,704
Thank you for the detailed answer!
Some questions:

1. 10 ohms is the cold resistance. I don't know the hot resistance because I didn't choose the NTC, so I don't have an R-T curve. Why should I know the hot resistance of the NTC? To dimension what?

2. I didn't know about this load thing with a resistor in series at startup .. can you give me an example of what kind of load can have problems? And how? I don't understand this...

3. I assume the voltage Vz2 is greater than Vi, right? A little less than the maximum V the comparator can receive at its input

4. R4 required because comparator has open collector output, right?

5. OK about galvanically isolating 12V from Vi ... but I don't understand two things:
- isn't an isolated DC-DC sufficient?
- I don't understand why you put ground there in the red arrow, you are connecting Vi to GND

Hi,

See new attachment.

1. It's nice to know the specs of the thermistor. We would know what it does before the relay turns on.
2. Saw motors or other motors. The current reduces when it starts to turn, if it can't turn current may not reduce naturally.
3. Yes, Vz2 should be greater than Vz1, with some margin. Vz2 just protects the input of the LM393.
4. Yes, R4 is a pullup.
5a. I do not know what kind of power supply you are using with this. With the new drawing though it should be ok.
5b. I meant to switch the load to the other side so we are sensing in the ground lead which makes the circuit more straightforward.
 

Attachments

Thread Starter

andrew74

Joined Jul 25, 2022
224
Hi,

See new attachment.

1. It's nice to know the specs of the thermistor. We would know what it does before the relay turns on.
2. Saw motors or other motors. The current reduces when it starts to turn, if it can't turn current may not reduce naturally.
3. Yes, Vz2 should be greater than Vz1, with some margin. Vz2 just protects the input of the LM393.
4. Yes, R4 is a pullup.
5a. I do not know what kind of power supply you are using with this. With the new drawing though it should be ok.
5b. I meant to switch the load to the other side so we are sensing in the ground lead which makes the circuit more straightforward.
Hi

Okey let's use this NTC .. I know it only supports 36A and not the "100A" that I had mentioned in the first main post, but it's to start doing some calculations (and remember this is a theoretical example, so we have a lot of freedom)

1) We choose Vz1, but how much? I think an arbitrary value, and based on that, we size R1 and R2 (?)

2) Any specifics in particular about the choice of Q1and R4? ..except the fact that its voltage on the base will be driven by 0 or 12V output from the comparator

3) On R3 I do not know how to proceed.
 

MrAl

Joined Jun 17, 2014
13,704
Hi

Okey let's use this NTC .. I know it only supports 36A and not the "100A" that I had mentioned in the first main post, but it's to start doing some calculations (and remember this is a theoretical example, so we have a lot of freedom)

1) We choose Vz1, but how much? I think an arbitrary value, and based on that, we size R1 and R2 (?)

2) Any specifics in particular about the choice of Q1and R4? ..except the fact that its voltage on the base will be driven by 0 or 12V output from the comparator

3) On R3 I do not know how to proceed.
Hello again,

I am thinking that a resistor would be better than a thermistor. That will give us a more well-defined behavior since we are more or less bypassing the thermistor behavior anyway.
1. Vz1 is partly based on the resistance of NTC which we can call Rs for now. The trip point occurs when the voltage at pin 2 (vp2) equals the voltage at pin 3 (vp3). That is, vp2=vp3.
The divider ratio of R1 and R2 and R3 produce vp3, and Z1 produces vp2. Since the output of the LM393 will be 0v at that point, the divider voltage is then similar to what you get with Vi and R1 and R2, but now you can consider R2 to be in parallel with R3, so calling this R23 the voltage vp3 is:
vp3=Vi*R23/(R23+R1)
which you could immediately recognize as a simple voltage divider. Vi here is the Vi at the top. To start the calculation, we want to set R3 to 100k which is a good tradeoff between noise and not loading the output of the LM393 when it goes high. R4 should start at 1k.
The value of R3 has to hold the LM393 output high when the surge goes away, and since we are effectively shorting out Rs (the NTC) we have to have the voltage vp3 stay greater than vp2 even then.

The above should get you thinking about what you have to do now, but first you should test for the resistance Rs. To do that, use a resistor (of the right power rating) in series with the load and see if the load can start up at least a little so that the surge current is limited, yet still stays low once you close a test switch wired in for the relay. Alternately, just wire the relay in so it is powered by hte same voltage that powers the load (with a decrease in voltage perhaps with a series resistor). When the power is turned on (Vi on the left not at the top) STARTS to turn on the relay but there is a delay because of the natural delay of the relay.
This test tells us if any of this will work in the first place. The load current has to decrease when it starts once the relay closes. It does not have to go super low, just something that we can call lower so that once the relay closes it does not go all the way back up to the max.

Q1 we can't choose until you tell me what relay is being used. We have to know the coil current and specified voltage. R4 can start at 1k or initial testing. Q1 may end up being a simple 2N2222 or might have to be more robust. The diode is 1N4004 or similar. R3 starts at 100k.

I hope this is starting to make more sense now. If not, it will once we go further. Let me know if you can handle the calculations for R1 and R2 and zener voltages.
If the voltage requirements of the zeners calculate out to go too low, we may have to use voltage reference diodes.
 

MrAl

Joined Jun 17, 2014
13,704
In this theoretical example is the surge produced by the spike and only for 3 ms during first powering up?
Or can one or more spikes happen anytime after power ON?
Hi,

Yes that brings up a good point about when and how the circuit has to reset. A strong requirement to consider.
 

MrAl

Joined Jun 17, 2014
13,704
Hello again,

For the circuit shown the two equations are:
(EiH*R2*R3)/(R2*R3+R1*R3+R1*R2)=Vz1-vh
and:
(R2*(EiL*R4+EiL*R3+E2*R1))/(R2*R4+R1*R4+R2*R3+R1*R3+R1*R2)=Vz1+vh
where
EiH is the highest input voltage from across the 10 Ohm resistance, EiL is the lowest which would be 0v.
Vz1 is the voltage of the main zener Z1.
vh is half of the total hysteresis voltage.
E2 is the DC supply voltage 12v as you have shown.

We can assume values for R3 and R4, then calculate R1 and R2 from the above after choosing some values for Vz1 and vh.
I found that R3 can be 10k and still get reasonable values for R1 and R2 that are not too large. I used Vz1=1 and vh=0.5 volts.

Also, since we probably want this to stay latched forever, we might parallel R3 with a diode and series resistor to ensure it always stays latched. I haven't tested this idea yet but it looks like it would work pretty well.

One question comes up though. If the input comes on and stays on, do we really need any circuit at all?
If the relay has its own delay, then once it is energized by the input voltage, it will turn on and stay on, unless the input goes away. If the input goes away then we would want the circuit to reset anyway.

So why not try with the relay alone first and see if any circuit is needed at all.
 
Last edited:

Thread Starter

andrew74

Joined Jul 25, 2022
224
This test tells us if any of this will work in the first place. The load current has to decrease when it starts once the relay closes. It does not have to go super low, just something that we can call lower so that once the relay closes it does not go all the way back up to the max.
If all this is to verify that the inrush current has dropped ... can't I just use a current probe and measure it?


For the circuit shown the two equations are:
vh ensures that the relay does not 'switch' in and out of the closed state due to small variations around the threshold? ..so it serves to make the behaviour stable

Can you show how you arrived at those formulas you wrote down? Or at least where to start ... because they already seem to me to be the 'final' ones
 

MrAl

Joined Jun 17, 2014
13,704
If all this is to verify that the inrush current has dropped ... can't I just use a current probe and measure it?



vh ensures that the relay does not 'switch' in and out of the closed state due to small variations around the threshold? ..so it serves to make the behaviour stable

Can you show how you arrived at those formulas you wrote down? Or at least where to start ... because they already seem to me to be the 'final' ones
Hi,



Sure. Basically, it's using Nodal Analysis to compute the voltage at the non-inverting input (call it v3) of the opamp/comparator. That voltage forces the behavior to be whatever we want the behavior to be, so it's the most important voltage to know.
I can show you the calculations step by step but you may want to try this yourself first so I'll wait a bit.
I had forgotten to show what E2 was in the formulas, it is the DC supply voltage currently you show as 12 volts.

The procedure is to calculate that voltage with the output grounded, so this only involves R1, R2, and R3. That gives us the first equation and is the one that brings us the initial action. That means we will consider the input will be at the high threshold just before anything else changes. That's the surge voltage across Rs the series sense resistor due to the surge current. We have to compare that to Vz1 to make sure it is above that in order to force the output to go high.

That would be the first equation, and the second equation is with the output in high impedance state so R4 is now in the circuit. That only means that now we have instead of just R3, we have R3+R4, and now we have a second voltage source which is +Vcc (12v in your case). This means we have to deal with two voltages, but we get lucky here because we can define the lower voltage after the relay closes to be zero, and that means we are back to just one source: +Vcc=12v.
So now we have the same network but with R4 included, and 12v powers that now. We then calculate v3 again, and compare it to Vz1 again. In order to keep it latched, it must be above Vz1.

So v3 has to be above Vz1 in both cases: as the surge first occurs, and after it is over. It will only be less than Vz1 when the power source 12v is turned on but there is no input to power the load yet. That's when the output of the opamp/comparator will be nearly zero.

There is one assumption for now. That is that the low of the relay coil does not load the emitter of the transistor too much to start with so that we get fast and clean snap action. That should be reasonable because the relay coil is inductive.
Another assumption is that the noise does not affect the switching action. Sometimes when a coil is energized or deenergized we can get a large spike of EMI which can interfere with sensitive electronics. The lowest impedance on the non-inverting input will be a governing criterion for this, which we can think about later if a problem comes up.

So again, if you want to try doing the nodal analysis (or whatever method you prefer) you can try that, or if you want to go through the math step by step I can show you that. If you don't like the math too much you can also try doing a simulation and see what you get.

I do want to reiterate that you probably want to try the direct relay energizing idea first. That should be a simpler circuit, if it works out ok in bench testing. It's up to you of course how you want to do this.

One chip that might work is the LTC4364HDE, but you can do a search for Surge Protection IC chips, and perhaps Hot Swap IC chips.
 
Last edited:

Thread Starter

andrew74

Joined Jul 25, 2022
224
A NE555 wired as below gives a delayed High output when first powered ON equal to 1.1RC and remains ON until powered OFF.
Fulfills circuit designs in #2 and #3.

View attachment 356664
Correct me if I am wrong, this circuit automatically closes after a fixed 1.1RC time, right? ..regardless of the inrush.
This means that if by bad luck or something else the inrush happens after that time, the problem remains.
This does NOT happen with the solution of @MrAl ? Right?

I am well aware that in the trace of my question I assumed inrush after x fixed ms, so your solution is fine!
But now, to complicate things a bit, I am assuming "random" inrush event, i.e. you don't know when it happens .. maybe after 1ms or after 2ms or after 5ms ...
 

panic mode

Joined Oct 10, 2011
4,984
so you want to detect overvoltage, use it as trigger to activate timer (3ms) and then have timer activate relay/ssr to bypass ICL.
but... what is the exact sequence of this "powerup"? because you stated that inrush can be "random". does that mean that after Vi is on (50V) there could be or perhaps multiple inrush spikes? if so when does the SSR power off?
 

panic mode

Joined Oct 10, 2011
4,984
if you only want to react on first spike, use comparator to trigger RS. add button (optional/testing only) and RC to reset RS on powerup. when RS is set, run timer (or RC delay followed by Schmidt trigger). output should drive SSR.
 

Thread Starter

andrew74

Joined Jul 25, 2022
224
Hello again,

For the circuit shown the two equations are:
(EiH*R2*R3)/(R2*R3+R1*R3+R1*R2)=Vz1-vh
and:
(R2*(EiL*R4+EiL*R3+E2*R1))/(R2*R4+R1*R4+R2*R3+R1*R3+R1*R2)=Vz1+vh
where
EiH is the highest input voltage from across the 10 Ohm resistance, EiL is the lowest which would be 0v.
Vz1 is the voltage of the main zener Z1.
vh is half of the total hysteresis voltage.
E2 is the DC supply voltage 12v as you have shown.

We can assume values for R3 and R4, then calculate R1 and R2 from the above after choosing some values for Vz1 and vh.
I found that R3 can be 10k and still get reasonable values for R1 and R2 that are not too large. I used Vz1=1 and vh=0.5 volts.

Also, since we probably want this to stay latched forever, we might parallel R3 with a diode and series resistor to ensure it always stays latched. I haven't tested this idea yet but it looks like it would work pretty well.

One question comes up though. If the input comes on and stays on, do we really need any circuit at all?
If the relay has its own delay, then once it is energized by the input voltage, it will turn on and stay on, unless the input goes away. If the input goes away then we would want the circuit to reset anyway.

So why not try with the relay alone first and see if any circuit is needed at all.
I found from the calculations your first equation, it was enough for me to develop the voltage divider.
But I didn't understand how to get to the second one (the numerator):
SmartSelect_20251015_211223_Samsung Notes.png
 

MrAl

Joined Jun 17, 2014
13,704
I found from the calculations your first equation, it was enough for me to develop the voltage divider.
But I didn't understand how to get to the second one (the numerator):
View attachment 357186
Hi,

Oh that's great that you got the first one, that means you can also get the second one.

The general method for any of these circuits is to use Nodal Analysis. There's also a sort of 'trick'. It's not really a trick but it may seem like one because we do the very same thing as we did with the first equation, except now we do it two times. We then sum the results.

Let's look at a simpler example first. Say we have just two resistors of a voltage divider, R1 on top and R2 on bottom. We have two voltage sources V1 and V2, V1 connects to the top of R1 and V2 connects to the bottom of R2 (both positive) and the negative terminals are both grounded.

Now to start, we short out V2. That gives us the first node voltage vn1:
vn1=V1*R2/(R1+R2)

now we do the same thing again but this time we short out V1 and use V2 as the only source. this gives us vn2:
vn2=V2*R1/(R1+R2)

and note that for vn1 we have R2 in the top and for vn2 we have R1 in the top. That is a consequence of the roles of the two resistors changing place. If we drew the circuit with just V1 we would have R2 on the bottom, and if we redrew the circuit with just V2 we would see R1 on the bottom because R1 would then also connect to ground.

Now we just sum the two voltages vn1 and vn2 to get the total node voltage:
vn=vn1+vn2
so:
vn=V1*R2/(R1+R2)+V2*R1/(R1+R2)

In any case were we happen to have two resistors in series we of course just add the two before we use that as either R1 or R2.

Just keep in mind that when we do the second calculation the entire topology may look different because we may end up with more resistors or less resistors in the second calculation. The two calculations are done independently from each other although they may share some or all resistors.

See if that helps.
 
Top