Relay coil power consumption
![VonSzarvas](https://forums.parallax.com/uploads/userpics/814/n2KKWCY80HQA7.png)
Hi all,
This forum is well stocked with matters relating to triggering relays directly from the IO pins, and that high caution must be observed!!
However, perhaps new relay technology is making the direct connection of certain low-power relays possible?
May I check my maths....
AZ850-5 microminature polarized relay
Coil power consumption: 79 - 142 mW. Lets say 0.15 watts.
Using the equation P = IV, therefore I = P/V.
I = 0.15watts / 5volts = 0.03 amps (or 30mA).
According to the SX datasheet, the pins will sink 30mA normal. 45mA absolute max.
So, am I right to think I could drive this relay (with the correct diode protection) directly from an IO pin ?
Or is that rather a risk and/or foolish calculation, and an external transistor would still be recommended...
Thanks for any tips.
Max.
Edited to add second calculation:
I also read that the same relay coil has a resistance of 178R.
I = V/R, therefore I = 5v / 178R = 0.28 amps (28 mA). That basically gives the same result as the power calculation above, just under 30mA.
This all sounds positive.
Post Edited (Maxwin) : 10/3/2007 9:47:58 PM GMT
This forum is well stocked with matters relating to triggering relays directly from the IO pins, and that high caution must be observed!!
However, perhaps new relay technology is making the direct connection of certain low-power relays possible?
May I check my maths....
AZ850-5 microminature polarized relay
Coil power consumption: 79 - 142 mW. Lets say 0.15 watts.
Using the equation P = IV, therefore I = P/V.
I = 0.15watts / 5volts = 0.03 amps (or 30mA).
According to the SX datasheet, the pins will sink 30mA normal. 45mA absolute max.
So, am I right to think I could drive this relay (with the correct diode protection) directly from an IO pin ?
Or is that rather a risk and/or foolish calculation, and an external transistor would still be recommended...
Thanks for any tips.
Max.
Edited to add second calculation:
I also read that the same relay coil has a resistance of 178R.
I = V/R, therefore I = 5v / 178R = 0.28 amps (28 mA). That basically gives the same result as the power calculation above, just under 30mA.
This all sounds positive.
Post Edited (Maxwin) : 10/3/2007 9:47:58 PM GMT
Comments
I'm using the SX to directly drive reed relays with several of my projects without any trouble. The relays I'm using have built-in flyback diodes and a coil resistance of 200 Ohms, which results in a current of 25 mA @ 5Volts. The SX datasheet specifies 45 mA max for sourcing or sinking current, so the 28 mA drawn by your relays should be fine.
Nevertheless, also keep in mind the specified maximum for the SX28 of 130 mA out of the Vss pin, or into the Vdd pin. IOW, when you want to drive two or more relays at the same time, make sure that the sum of all currents out of, or into output pins plus the current the SX consumes itself does not exceed this maximum value. For the SX48, the maximum specified is 300 mA at 25°C (or 180 mA at 70C) but this requires that all four Vdd and all Vss pins are connected to the power supply.
In addition, the SX48 datasheet specifies a maximum of 50 mA sink or source into or from a group of I/O pins. Although the SX28 datasheet does not show this limitation, I assume it is true for the SX28 as well.
In case you plan to activate more than two relays at the same time from one group of outputs, I think it is a good idea using additional driver transistors, or a driver IC for additional safety.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Greetings from Germany,
Günther
Just be sure and use a reverse biased diode, if your relay does not have one, and observe the maximum current limit per port as well as per I/O and you should be ok.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
I agree with Beau - he briefly pointed out all the important points.
BTW: An interesting alternative to driver transistors are photo couplers, like the 4N29, etc. You can find various devices that can handle a maximum of 150 mA (or more) continuous collector current, so they can be used to directly drive even larger relays with the advantage of an electrical isolation between the SX side, and the relays. This way, the SX output currents can be reduced to some mA per output, provided the photocouplers have sufficient transfer ratios.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Greetings from Germany,
G
I have isolated the relay onto the RA.x range, so that nothing else is running off the RA.x pins. I have assumed by port you meant the 3 ranges (sx28) of RA.x, RB.x, RC.x, and that per G
Connections: relay+ to RA.0, relay- to Vss, diode 1n4148 across relay+ & relay-, diode stripe side to relay+
SX/B code:
Using a digital multimeter in series with the relay- to Vss connection, I can measure maximum 24.6mA when the relay is activated.
Max.