240/250V relay question

I am trying to control a number of standard home voltage (240/250VAC) from an arduino. Currently I am at the state of putting a list together of what is needed to get this working. This is where I found thist post:

http://declanbright.awardspace.info/arduino-home-automation-heating-lighting.htm

which suggests that I can connect the relay straight into the arduino. Other posts online and on this forum however suggest a transistor etc for this.

however these were using different relays for this.

I was looking at using this relay : http://www.photosensor.com.tw/Solid%20State%20Relay/Single%20Phase%20Solid%20State%20Relay%20(DC%20to%20AC%20SSR)(UL)/SSR-25DA.htm which has a control voltage of 3~32VDC and seems to be within the limits of the power output of an arduino ?

Any pointers if this can be done direction using this relay of if I require other components.

I would also like to find out how many of these relays I would be able to control with a single arduino ?

This is a solid state relay which is not a relay at all just a bunch of components that switch mains on and off. When it is off it is still connected so it can give you a nasty shock.

Having said that, yes you can use them and you can control as many as you want from an arduino, however it is mains so any miss connections are not forgiven easily.

It is a much safer option to use a transistor and a separate power source.

5v relays can not really handle much of a current.
And there are limits of how much current you can take from (source) or send to (sink) a single pin (0.04A). Load on all the pins should not exceed 0.175A (0.2A through the chip - 0.025A used by the chip itself).
Bottom lime is: if your arduino is to fail you will not only have to replace it but rebuild your project anyway.

How many (channels) relays can be used at a time? As many as there are pins available on the board (if not bother to multiplex).

Consider also using latching relays they are generally 4x more expensive that eliminates the need to keep them powered all the time.
Other thing to look at are transistor arrays - that is if you want to use lots of relays at once. That saves cost and space on the board.

Take care with mains voltage…

I would buy a pre-assembled Arduino compatible relay board. I've seen them with 1, 2, 4, 8 and 16 channels. Many of them can handle 10A @ 240V loads. If the load is greater than 80% of the relay rating, I would use the relay to drive a contactor.


If you're sold on using SSRs, yes, you can directly connect them to the Arduino. Your specs say the SSRs have a 7.5 mA trigger, the Arduino DOs are rated at 40 mA so directly connecting them means 5 or less per DO.

As a simple safety feature, I would separate the Arduino from the SSRs with an opto-isolator.

I would buy a pre-assembled Arduino compatible relay board. I've seen them with 1, 2, 4, 8 and 16 channels.

Unless you need to build your own board with other properties these may be the easiest/cheapest approach:
http://goo.gl/8ZEQ8

As a simple safety feature, I would separate the Arduino from the SSRs with an opto-isolator.

The isolated versions are almost the same price: http://goo.gl/3jds9

Lost of people are using these and they seem to work well...

DISCLAIMER: Mentioned stuff from my own shop...