Electronics > Projects, Designs, and Technical Stuff

Thoughts on driving solenoids and relays

(1/4) > >>

naxxfish:
Hi, forum!

Ever since I started tinkering, doing hobby electronics, and aiming in the direction of mechatronics, I am persistently plagued by the problem of driving inductive loads of various sorts. I managed to get my head around driving standard hobby level DC motors ( http://tinkersoc.org/wiki/reference:motordriver ), and built a motor driver board with an IC designed for the job, which does the job excellently.

However I am doing a bit of freelance stuff during my vacation from my degree - and I will be working with solenoids.  They're for a museum exhibit that has broken.  As I've not yet actually seen the kit, I can't tell what exactly is broken - but it made me wonder about the practicalities of driving relays and solenoids and the like. 

For a previous project, I designed a (probably over complicated) relay module to connect to a micro to set off fireworks. It had an optocoupler (which didn't work), darlington pair amplifier, flyback diode, as well as some dampening to prevent chattering. Ended up bypassing the optocoupler, and in the end the darlington pair, and driving it with a nail on a stick touching against a battery terminal. 

Anyway - my question is this: what are the major things that need to be considered when designing a circuit to drive an inductive load like a large-ish solenoid.  How much protection is required, really?  Should I bother with an optocoupler, or would I get away with going straight into a FET?

I also found this:
http://electronicdesign.com/article/power/smart-solenoid-driver-reduces-power-loss11162.aspx

Which is very nice and economical, but my op-amp skillz are somewhat lacking (I did a module in my course on opamps about 3 years ago now, and my degree is more oriented towards the digital side of things so haven't come back to them since) and I don't really understand it, so am hesitant to pick it up and run with it. 

DJPhil:

--- Quote from: naxxfish on August 19, 2010, 11:56:25 pm ---How much protection is required, really?  Should I bother with an optocoupler, or would I get away with going straight into a FET?
--- End quote ---

I'm not a pro, but I believe the flyback diode should be adequate unless you need high speed (see this EDN article on bootstraping). Remember to use a beefy one, not a signal diode. You can always test a given rig 'dead bug' style if it's just a few parts to see how it's behaving without cooking a micro. Optos are very useful, but probably not necessary unless you have intractable noise problems or need the extra isolation for safety, i.e. working with a mains relay.


--- Quote from: naxxfish on August 19, 2010, 11:56:25 pm ---I also found this:
http://electronicdesign.com/article/power/smart-solenoid-driver-reduces-power-loss11162.aspx

Which is very nice and economical, but my op-amp skillz are somewhat lacking (I did a module in my course on opamps about 3 years ago now, and my degree is more oriented towards the digital side of things so haven't come back to them since) and I don't really understand it, so am hesitant to pick it up and run with it. 

--- End quote ---

That's a pretty slick circuit, but it might be overkill unless you need the power savings. Still . . . Looks like a good reason to brush up!

Opamps aren't too difficult as analog goes, just don't get bogged down in high performance details too early. The best treatise on opamps I know of is Opamps for Everyone, and it's free! Don't be intimidated by the size, a quick spin through chapter 3 will get you refreshed on the ideal model. Opamps are just way too useful to skip!

Hope that helps. :)

Zad:
Off the top of my head (and realising that at this hour I should be asleep in bed) how about putting an electrolytic capacitor on the base of the transistor to reduce the speed at which the current is turned on and off through the solenoid? It is the speed of this current change (di/dt) that dictates how high the reverse EMF is that it generates. It would mean that the transistor dissipated more power whilst not fully saturated, but it should be quite a short duration.

Simon:
really all you need is a mosfet like a IRF540 or 9540 and a back EMF diode, simple (not looked at your diagram yet as on my way to work)

Time:
You just need an appropriate diode to handle the back emf.  If the solenoid/relay isn't being switched often enough power consumption might be negligible.

Navigation

[0] Message Index

[#] Next page

There was an error while thanking
Thanking...
Go to full version