Step 2: The Hardware
The basis for my project was my Arduino Ethernet controller board - I simply connected 6 switched relays of some spare I/O lines, and designed a new PCB layout because I enjoy the quiet Zen state when I am laying out a new PCB.
There is nothing stopping you from putting a set of relays onto a piece of stripboard, and running them from an Arduino board with an Ethernet shield. The only caveat is that the Ethernet shield has to be based on the ENC28J60 chipset. That is what I support in my code.
Here is the circuit diagram of one of the relay outputs. You can see that each relay is driven using a BC547 transistor. There is nothing fancy about the BC547 (except that they cost about $0.03 in quantity) you can use whatever type of NPN switching transistor you like. There is a current limiting resistor between the base of the switching transistor and the Arduino output to protect the transistor from damage. There is also a spike protection diode across the transistor to protect it from the large electrical spike that occurs when the relay is switched off. There is also a LED installed so that you can visually see the state of the outputs.
You will also find the full schematic diagram for the project here as a PDF. For more information, have a look at my Ethernet Arduino Instructable.
Update - It was suggested that the protection diodes should be placed straight across the relay - so I have amended the pcb layout, as well as fixed the schematic. Thanks for that!
Ethernet-Relay-Controller-Schematic-v1b.pdf(842x1190) 112 KB
Remove these ads by
Signing Up









































Visit Our Store »
Go Pro Today »



On the Arduino.cc website there is a link for a parallel port programmer that does not ask much more than a subd 25 connector and some resistors.
For sending programs to the bootlaoded chip, consider serial upload:
http://arduinodiy.wordpress.com/2012/03/19/serial-connection-for-your-arduino-atmega/
All of my projects have a 6 pin header that is designed to use this cable to program the chip.
Doug
Here is a the URL:
http://www.jaycar.com.au/productView.asp?ID=SY4050&keywords=relay&form=KEYWORD
I am a little confused about your second point - the NP N transistors dont conduct unless there is base drive, so I don't understand your comment?