Shield User Manual
Shield User Manual
User Guide
www.numato.com
You may use, modify or share this publication or part of thereof adhering to Creative Commons Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0) License. See complete license text at http://creativecommons.org/licenses/by-sa/3.0/
All trademarks are property of their respective owners.
Introduction
Numato Lab's 4 Channel Relay Shield provides an easy way to control high voltage/current electrical and electronic devices. It has four 12V DC SPDT mechanical relays that can switch up to 10A DC or 12A AC current load. Individual LEDs available on the board indicates the state of the relays. All contacts on each relay are brought out separately on screw terminals. External voltage provides power supply to this shield, connect a 12V DC voltage to the external screw terminals on the board with correct polarity. Some of the possible uses of this shield include Home Automation Lighting Control Garden Equipment Control Industrial Automation Test Fixtures DIY and Hobby
Features
Arduino Uno, Arduino Mega compatible shield. 4 SPDT mechanical relays. ULN2003 IC is to drive relays. Individual LEDs are available for indicating the relay state. Screw terminals are equipped for connecting external devices. Arduino stackable female headers are available for shield extending purpose. Small size, Low cost and Light weight.
This shield can be used to control a large number of devices including lamps, motors, locks etc... (Please see recommendations for using this product with inductive loads elsewhere in this document). The popular ULN2003 IC is used to drive the relays individually, the inputs of the ULN2003 IC are connected to the Arduino digital pins(8, 7, 2, 4) and the outputs of the ULN2003 IC are connected to relays(0, 1, 2, 3) respectively. Writing HIGH to these digital pins makes corresponding relay to ON and vice versa writing LOW to these digital pins makes corresponding relay to OFF. LEDs on the board indicates the ON and OFF state of the relays individually. The Demo code provided on the product page at www.numato.com makes it easy to get you started with this shield. Individual relays can be controlled by sending simple numbers(00,01,10,11etc..) to serial monitor, in which the first digit stands for relay number and the second digit stands for relay state (1 for ON and 0 for OFF). Sending 21 will put the relay 2 in ON state and sending 20 will put the relay 2 in OFF state. User can write their own sketch for controlling the relays according to the application. The miniature size and light weight of the board makes it compatible for small sized applications.
Connection Details
IMPORTANT Please exercise utmost caution while working with electrical mains or other
high voltages. Failure to comply with safety regulations may result in injury and or death.
Connection Diagram
Above image shows basic connection diagram that can be used in most of the situations. The connection diagram is same for both AC and DC loads. Please make sure to use a freewheeling diode or snubber circuit if the load is inductive. More details about using inductive loads is available elsewhere in this document. Use a USB A to B cable to connect Arduino to the host PC. It is important to make sure that the wires used to connect loads are sufficiently rated to handle expected load current. Exercise caution while working with high voltages. Short circuits can cause damage to the shield, host system or even to you. The following sections identify individual connections in detail.
Relay Contacts
All contacts on each relay are available externally on screw terminals for easy user access. The relays are rated for AC and DC supply voltages. Please see the electrical parameter table for more details. Each relay has three contacts(C, NO and NC). C is the common terminal and is used in both normally open and normally closed positions. The contacts NC and C will be connected when the relay is turned off and will be disconnected when relay is turned on. And vice versa, the contacts C and NO will be disconnected when relay is turned off and will be connected when the relay is turned on. Table below summarizes possible relay contact positions.
Relay State Connection between NC and C Connection between NO and C OFF ON Close Open Open Close
DC Power Supply
The External Voltage provides power supply for this shield. Connect a 12V DC supply to the screw terminals on the board. Any off the shelf 12V DC power supply can be used for this purpose. Please make sure to connect the power supply in correct polarity. Connect the positive terminal of the power supply to +12V terminal on the shield and connect negative terminal of the power supply to GND terminal on the shield. Connecting power supply incorrectly can cause damage to the shield and/or other devices.
1. 2. 3. 4. 5.
Install 4 Channel Relay Shield on Arduino Uno (or compatible) board. Connect 12V DC power supply to the screw terminals on the shield. Download Arduino Demo code from http://www.numato.com. Open the code in Arduino IDE, compile and upload to the Arduino board. Individual relays can be controlled by sending simple numbers(00,01,10,11,etc..) to the Arduino serial monitor. The table below summarizes the input number to serial monitor and corresponding state change of relay. Input to serial monitor Relay number 00 01 10 11 20 21 30 31 Relay0 Relay0 Relay1 Relay1 Relay2 Relay2 Relay3 Relay3 Relay State OFF ON OFF ON OFF ON OFF ON
Additional Information
Using relay modules with inductive loads
It is important to take additional care when using relays with inductive loads. An inductive load is pretty much anything that has a coil and works based on magnetic principles like Motors, Solenoids and transformers. Inductive loads produce back emf when the magnitude of the load current changes. The back emf can be in the order of tens or even hundreds of voltage (See this Wikipedia article http://en.wikipedia.org/wiki/Counter-electromotive_force). This effect is most severe when power is disconnected from inductive load because the rate of change of current is maximum at that point. Even though the back emf lives only for a very short time (a few milliseconds) it can cause sparks between the relay contacts and can deteriorate the contact quality over time and reduce the life span for the relays considerably. So it is important to take countermeasures to suppress the back emf to acceptable levels to protect relay contacts. Usually this requires connecting electronic devices in parallel with the load such that they absorb the high voltage components generated by the load. For solenoids, connecting a diode (fast switching diode is recommended) in parallel to the load (in reverse direction to the load current) is very effective. A diode used for this purpose is usually called a freewheeling diode. Please see the diagram on the right for connection details. A capacitor with proper rating is recommended for protecting the relay contacts when a motor is used as load. The capacitor should be rated enough to withstand the back emf that is generated by the motor. Please see the diagram on the below right for connection details. Please note that the relay modules are NOT shipped with back emf suppression devices preinstalled. The exact kind of suppression device and the parameters of the selected device can vary depending on the load itself. Some of the parameters that affects the suppression device selection are the inductance of the load, power supply voltage, load current, physical size/structure of the load etc.. It is obvious that it is impossible for us to predict these parameters and design required back emf suppression device and incorporate that on the board. So we believe this is a task best left to the module user. There is an excellent article on designing back emf suppression on Wikipedia at http://en.wikipedia.org/wiki/Flyback_diode
Technical Specifications
Parameter *
Basic Specifications Number of relays Supply voltage to shield Maximum current drawn by shield Relay Specifications Nominal relay coil voltage Nominal coil power consumption (per relay) Relay contact material Contact rating 12 400 AgCdO 10A/125V AC 10A/250V AC 10A/28V DC 110V DC/240V AC 12 1800VA, 360W 50 100,000 10,000,000 500 8 5 m Operations Operations M mS mS A V mW 4 12 130 V mA
Value
Unit
Maximum switching voltage Maximum switching current Maximum switching power Contact resistance (initial) Life expectancy (Electrical) Life expectancy (Mechanical) Nominal insulation resistance Maximum switching on response time Maximum switching off response time
*
All parameters considered nominal. Numato Systems Pvt Ltd reserve the right to modify products without notice.
FAQ
Q. Where do I find Demo code for this product? A. Visit http://numato.com and navigate to the product page. There will be a link to download Demo code. Q. I need a customized version of this product, can Numato do the customization for me? A. Yes, we can definitely do customization but there may be minimum order requirements depending on the level of customization required. Please write to [email protected] for a quote. Q. Where can I buy this product? A. All Numato products can be ordered directly from our web store http://www.numato.com. We accept major credit cards and Paypal and ship to almost all countries with a few exceptions. We do have distributors in many countries where you can place your order. Please find the current list of distributors at http://numato.com/distrib.