Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Will this be safe?

Status
Not open for further replies.

Boncuk

New Member
Hi,

this is the first time I have to deal with a relay drawing relatively high coil current (5VDC/180mA)

(Using another type of relay isn't possible due to customer's requirements.)

I'm afraid the relay will cause power fluctuations on the regulator output to cause problems for the MCU supply (VCC).

So I designed the supply like that.

Will this be safe enough for the MCU not to crash?

Boncuk
 

Attachments

  • HC-RELAY.gif
    HC-RELAY.gif
    12.1 KB · Views: 218
You can simulate the power supply with 180mA load to see if it goes below xx volts -- signifying the state you're trying to avoid.

You can also run the relay using a 2 stage drive; a high-current turn on, and a low current (50% is fine, can go lower, but you'd have to check out what the relay drops out at -- datasheet says 10% min but I wouldn't go anywhere near that).

You can either place a capacitor across the series resistor, or use another transistor with RC network or another micro pin. The diodes D1 and D2 are not required in your circuit.
 
I'd remove D1 and D2 which aren't needed.

There's no need to regulate the voltage to the relay coil, just use Ohm's law to calculate a value for R3 that will drop about 6.3V at 180mA. With 39R for R3 the voltage across the relay coil will already be below 5.1V so D2 will be doing nothing.

R1 isn't needed, the MCU is push-pull so it will turn the MOSFET off without a pull-down resistor.

Heck, I'd even consider removing R3 and PWM the relay so the coil current stays at about 180mA which could probably be cut to 90mA once it's activated. The trouble is you don't know the coil inductance to getting the right frequency will require some experimentation.
 
hi Hans,:)
Just run your design thru LTspice.

Can you confirm the VA rating of the transformer.?

You are showing 222mA,????
 
C6 and L1 will ring at 160kHz so be careful not to excite it.
 
hi Hans,

Ref to our Chat line figures, this is what I am showing, perhaps other spice user will have some input.:)
 

Attachments

  • AAAimage03.gif
    AAAimage03.gif
    29.9 KB · Views: 178
  • Hans1.asc
    3.8 KB · Views: 167
I don't have the model or symbol for the LM7805, please post it.

C2 is too small, make it at least 2200µF and it should be better.
 
I don't have the model or symbol for the LM7805, please post it.

C2 is too small, make it at least 2200µF and it should be better.

hi hero,
I got it as regulator package from LTS. Yahoo.

If you cant find I'll send the lot.:)

EDIT: Found it!!!!

**broken link removed**
 

Attachments

  • 78xx Series.zip
    4.5 KB · Views: 126
Last edited:
R1 isn't needed, the MCU is push-pull so it will turn the MOSFET off without a pull-down resistor.

I found I needed pull-downs with a 2n7000 and a PIC, is this a general rule or does it differ? Without the pull-downs the FET 'latched' on until the gate was grounded.
 
hi hero,
I got it as regulator package from LTS. Yahoo.

If you cant find I'll send the lot.:)

EDIT: Found it!!!!

**broken link removed**
Just signed up.

I found I needed pull-downs with a 2n7000 and a PIC, is this a general rule or does it differ? Without the pull-downs the FET 'latched' on until the gate was grounded.
I don't see why you'd need pull downs, the PIC has a push-pull output stage and will connect the gate to 0V anyway when it's turned off.
 

Attachments

  • 78xx Series.zip
    4.5 KB · Views: 110
Last edited:
I noticed just after I posted and edited my post but you saw it too soon.
 
I still can't simulate your circuit because the relay symbol is missing.
 
I still can't simulate your circuit because the relay symbol is missing.

hi,
Just use an inductor/resistor combination.

EDIT: hero, I use these relays.
**broken link removed**
 
Last edited:
The resistor value is easy but what inductance value did you use?
 
LTspice really needs a compile feature so all non-standard libraries can be bundled with the circuit.

I was right, increasing C2 to 2200µF will get rid of the problem.

2200µF appears to be the minimum value though so go with 2700µF or even 3300µF.
 

Attachments

  • relays.zip
    5.9 KB · Views: 102
Last edited:
LTspice really needs a compile feature so all non-standard libraries can be bundled with the circuit.

I was right, increasing C2 to 2200µF will get rid of the problem.

2200µF appears to be the minimum value though so go with 2700µF or even 3300µF.

hi hero,
Hans is on the Chat line at this time.:)
 
ericgibbs,
There's an error in your transformer model. You set the secondary resistance to 28Ω, so no wonder the voltage drop was too high.:D

I tried setting the primary and secondary resistances to 30Ω and 1Ω respectively but it made the simulation too slow so I've included separate resistors to model it.

To ensure the relay turns on, the series resistor should be 33R or 27R and must be rated to 2W.

It will be fine even with 470µF for the filter capacitor (providing you don't connect any larger loads to it) but there's no harm in it being 1000µF.
 

Attachments

  • Hans1.asc
    4.1 KB · Views: 144
ericgibbs,
There's an error in your transformer model. You set the secondary resistance to 28Ω, so no wonder the voltage drop was too high.:D

I tried setting the primary and secondary resistances to 30Ω and 1Ω respectively but it made the simulation too slow so I've included separate resistors to model it.

To ensure the relay turns on, the series resistor should be 33R or 27R and must be rated to 2W.

It will be fine even with 470µF for the filter capacitor (providing you don't connect any larger loads to it) but there's no harm in it being 1000µF.

hi,
Since further talking to Hans it appears the transformer secondary is approx 13R.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top