January 2016
I’m using an Arduino to control a set of relays, and both the microcontroller and relays share a 9V power bus. I plan to put a diode across the relays to clip any reverse voltage spikes. Is there anything else I should consider to prevent a spike from the relays from shutting down the processor?
Please log in to post an answer.
Depending on your design layout and other components, I would suggest using a TVS (Transient Voltage Suppression) diode. While a conventional freewheel diode may be sufficient, not many clipping networks work in the picosecond range of a TVS. Placement of the TVS should be close to the source of the transient with as short a connection as possible.
Common TVS operating voltages range from 5V to 440V. They may be unidirectional (fine for relay coil flyback clipping) or bidirectional (AC transient suppression). If you can’t find one with the exact clipping level needed there are methods for adding to the clipping voltage by placing fast silicon diodes in opposing series (cathode to cathode) with the TVS. Adding a fast silicon diode in this way will increase the transient suppression clipping point by the silicon diode junction voltage drop (.7V).
Another option would be to use a Snubber Network. Again, use of these would depend upon your circuit layout and conductor lengths. These are simple RC networks. You can build your own by placing the correct capacitor and resistor in series across the relay coil or purchase a snubber as a unit. A TVS is usually less expensive and easier to add to the design.
The inductive reaction from opening a circuit which contains an inductor (relay coil) is due to the reverse voltage generated by the collapsing magnetic field around the coil when the current is interrupted by opening the contact. This high voltage can cause arcing across the contacts or spike on electronic components which leads to their demise.
For a DC powered circuit, you could add a snubber circuit (series resistor and capacitor) in parallel with both the diode and relay coil as shown in the Figure. Just make sure the resistor and capacitor can handle the power discharged from the diode coil when the contact opens. For an AC circuit you can use a properly sized Metal Oxide Varistor (MOV) to snub the spike.
When controlling inductive loads, I like to use an N-channel MOSFET such as a 2N7000, BS107 or equivalent to control the device in addition to the flyback diode. This provides further isolation and reduces the current requirement of the Arduino just in case you want to control more that a couple of relays.