0
\$\begingroup\$

I'm trying to make a backup power supply for a home WiFi router (12V, 0.5A) and observe that the relay release time for a QYT73 relay is around 1 second. That is enough for the router to reboot, which is undesirable.

The issue

When AC power switches off (power outage,) I expect the relay to instantly switch power to a battery (5msec. according to the relay datasheet,) but it takes approximately one second for the relay to release contacts, which is enough for the router to lose power and start rebooting.

I have a suspicion about the AC-DC adapter. It looks like it has some capacitance and after the AC is off it takes some time for the capacitor to unload, while the voltage drops enough to switch off the router before the relay coil releases the contacts.

Oddly enough, when the DC power source is back again, the relay switches to connect C-NO instantly, so the router doesn't recognize the switch and does not reboot.

Question

Is there any way to make the voltage/current drop on the relay coil faster so the relay release time will come closer to the datasheet value of 5 milliseconds?

Circuit purpose and description

I'm using a QYT73 relay to switch between the main power source (AC-DC adapter output 12V 0.5A) and a 12V battery.

Relay Datasheet Values
Coil Nominal Voltage - 12V
Nominal Current - 30mA
Coil Resistance 400Ω
Operate time (8msec. Max)
Release time (5msec. Max)
Pick-Up Voltage (Coil Nominal Voltage 75%) - 9V
Drop-Out Voltage (Coil Nominal Voltage 5%) - 0.6V

When a DC source is on, it also powers the relay coil and current to the load goes through (C->NO) contacts of the relay. When the DC source powers off, a relay should release contacts C->NO and switch to the power from a battery (C->NC.)

Router Backup Circuit

\$\endgroup\$
5
  • \$\begingroup\$ Is the current being slowly reduced a condition you have to deal with, or would a solution that causes the current to reduce faster be acceptable? \$\endgroup\$
    – Hearth
    Dec 18, 2022 at 22:03
  • \$\begingroup\$ Hi @Hearth! Looks like a slow release of current on a coil is a condition to deal with until the solution to reduce it faster is found :) I'm a total newbie in circuits, so guessing the solution here would be to somehow make the internal capacity of the AC-DC adapter release faster/instantly to speed-up the voltage drop on a relay coil - but how? For now, it works, but what is not good: the router is reloading when power is switched from the DC adapter to Battery, which is not good for the router and not good for continuous internet connection (which is sometimes critical) \$\endgroup\$
    – rodikno
    Dec 18, 2022 at 22:11
  • \$\begingroup\$ Well, the obvious solution to me is to do something to discharge the adapter faster. Or just use an AC relay. \$\endgroup\$
    – Hearth
    Dec 18, 2022 at 22:14
  • \$\begingroup\$ @rodikno An off-hand comment elsewhere made by PStechPaul touches on the first thought I was having. Why not just buy and use a 'mains' relay? They don't require a lot of power (less than 2 watts for the big and heavy 40 A switching devices I have here.) And they certainly don't need a secondary power supply to operate them. If it's just directly jacked into the mains, it will engage and just sit there dissipating a watt or two. When the power fails, it will immediately release. And they come in SPDT and DPDT and 4PDT varieties. \$\endgroup\$
    – jonk
    Dec 19, 2022 at 5:41
  • \$\begingroup\$ I'm pretty sure the relay does not take 1s to switch over. If it does, it's the first one I've ever seen that does. It's a switch that happens to be activated by a current. The contacts are open or closed (pretty much). What is happening is that the voltage is decaying slowly (as you suggest) and the OFF voltage for the relay is likely something like 7 or 8V. A crude but simple solution is to put a low value zener, like 5V or so in series with the relay. But if you want more precise behaviour you could control the relay (or a solid state switch) via a sense circuit triggered by a comparator. \$\endgroup\$
    – danmcb
    Dec 19, 2022 at 7:08

3 Answers 3

1
\$\begingroup\$

Here is my idea for implementing a backup transfer switch using a PNP transistor and two resistors (which set the crossover voltage):

Battery Backup Switch

\$\endgroup\$
2
  • 1
    \$\begingroup\$ Thank you @PStechPaul! I've ordered these components, will implement it soon and share the result, an instant voltage drop looks like a perfect fit here \$\endgroup\$
    – rodikno
    Dec 21, 2022 at 23:28
  • 1
    \$\begingroup\$ Finally implemented and it works perfectly, thank you for a circuit and calculations! \$\endgroup\$
    – rodikno
    Jan 17 at 19:34
0
\$\begingroup\$

The delay in relay dropout may be addressed by using a 12 V ~ relay.

Here's a comprehensive solution which includes a battery charger.

enter image description here

\$\endgroup\$
2
  • \$\begingroup\$ It's probably easier to find a 120 VAC relay than 12 VAC. And then the added supply would not be needed \$\endgroup\$
    – PStechPaul
    Dec 19, 2022 at 4:05
  • \$\begingroup\$ For sure, @PStechPaul. The modem 12V DC power supply would be a wall wart. A wall wart charger and wall wart 12 V ~ supply would help avoid mains wiring. \$\endgroup\$
    – vu2nan
    Dec 19, 2022 at 5:19
0
\$\begingroup\$

I have a suspicion about the AC-DC adapter. It looks like it has some capacitance and after the AC is off it takes some time for the capacitor to unload, while the voltage drops enough to switch off the router before the relay coil releases the contacts.

If the relay takes one second to release that is the most likely explanation. A relay can't be that slow, but a switching power supply turning off definitely can.

The problem seems to be that the voltage required to keep the relay on is lower than the voltage required to keep the router on.

One simple way to make a backup power supply is to just use a pair of diodes from each power supply to the load, to make sure one power supply always feeds the load. The power source with highest voltage will feed the load, so this requires a battery that has lower voltage than the mains power supply.

If you want to use a relay, what you need is a comparator monitoring the 12V supply and switching the relay when voltage begins to drop. For example you could set the threshold at 11V. This will be much quicker than a relay that remains on until voltage on the coil drops to a few volts. Here's an example with TL431 as comparator, it will switch at 10.9V:

enter image description here

\$\endgroup\$
3
  • \$\begingroup\$ You can also add a resistor in series with the commutating diode, which will more quickly dissipate the stored inductive energy. Probably about 200 ohms for a 400 ohm relay coil. \$\endgroup\$
    – PStechPaul
    Dec 18, 2022 at 23:09
  • \$\begingroup\$ I tried simulating this, but the resistor does not seem to help much. In fact, it causes a considerable negative voltage on the coil. But I used 500 mH as the relay coil inductance, so it may be more pronounced if it's much higher. With 500 mH, the current reaches zero in less than 5 mSec. There may be additional delay due to remanent magnetism and other effects not easily simulated. \$\endgroup\$
    – PStechPaul
    Dec 18, 2022 at 23:41
  • \$\begingroup\$ Using two steering diodes looks like the simplest solution. Otherwise, the AC relay should work, or the comparator as described above. It might be possible to make a comparator using a PNP transistor driving the relay coil on the collector, PSU on emitter, and battery on the base. \$\endgroup\$
    – PStechPaul
    Dec 19, 2022 at 0:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.