Relay

Switching for AC or DC devices

Warning
CAUTION: only connect this module directly to AC grid power if you already have prior experience with mains AC circuits, and carefully follow the safety recommendations at the bottom of this page. Misuse of this module might cause ELECTRIC SHOCK and FIRE. We do not recommend using the Relay Nanoshield in 220V applications (in this case, use the Triac Nanoshield).

The Relay Nanoshield is the most versatile of the actuator Nanoshields, because it can be user to switch AC or DC loads, and also has both normally open and normally closed contacts. Depending on the connections used, this allows a device to be turned on even when the Relay Nanoshield is not supplied with power.

The activation the relay is done with an I/O pin from the Arduino, going through a transistor to minimize the current provided by the I/O pin. There are 4 options to use for the I/O pin (D3#, D5#, D6# e D9#), which can be easily selected using jumpers on the board. In case these four options are not enough, there are 7 more options that can be selected by solder jumpers at the bottom side of the board (D2, D4, A1, A2, A3, A4 e A5). The relay is activated when there is a high logic level on the correponding I/O pin (keeping contacts C e NA closed), and deactivated when the there is a low logic level on the pin (keeping contacts C and NF closed).

Relays usually need a relatively high current (between 70mA and 120mA) to drive their coils during switching, and this can cause an overload in the Arduino internal voltage regulator in case it is the source of all this current – and the problem is aggravated if you need to use two or more relays simultaneously. Because of that, we included an integrated voltage regulator for each Relay Nanoshield, and in this case it doesn't add any extra load on the Arduino voltage regulator, allowing you to use many modules simultaneously without any overheating problems.

The switching of a relay is done by mechanical contacts, hence it is slower than solid state components like transistors and triacs. For that reason, the relay is not recommended for applications where a fast load switching is needed, like light dimmers and motor speed control, for example (for these applications, check the Triac and Mosfet Nanoshields). However, a mechanical contact has a very low electrical resistance and heat dissipation, allowing switching of high currents with a small relay and little heating. Other advantages of using a relay are the isolation between the control signal and the output contacts, and the possibility of using it either on the low side mode or in the high side mode.

Features

  • Can switch loads of up to 30VDC or 127VAC.
  • Current capacity of 3A for the normally close contact and 5A for the normally open contact.
  • 4 options for the output pin to use, selectable by manual jumpers, and 7 additional pins selectable by solder jumpers.
  • Operates with 5V or 3.3V in the control signal.
  • Transistor-based control, minimizing the current that needs to be provided by the microcontroller pin.
  • Integrated voltage regulator, avoiding extra burden on the Arduino voltage regulator.
  • LED indicating if the relay is on or off.

Relay diagram

Example of an assembly with 4 Relay Nanoshields being used simultaneously with an Arduino Uno.

Electrical specifications

  • Power supply: it can be done through either the VIN pin or the VCC pin. The voltage range for the VIN pin is from 7V to 12V (maximum 20V); for the VCC pin, the range is from 4.5V to 5.5V (5V typical). When power supply is present on the VIN and VCC pin simultaneously, the VIN input has precedence and will automatically be selected to supply the circuit.

  • Current consumption: the maximum current consumption is of approximately 90mA.

  • Logic levels: the relay can be activated with a logic level of 5V or 3.3V.

Safety recommendations

Please follow the recommendations below before using this Nanoshield or any other device that is directly connected to the mains AC grid power supply.

  • Keep in mind that AC mains current can be very dangerous. Accidents can cause injuries and even death. Hence, only use this equipment if you have prior knowledge about mains electrical circuits and if you are absolutely certain of what you are doing. If you are a beginner who is starting to play with electronics, do not use this Nanoshield or any other equipment which has a direct connection with the mains AC grid.
  • Certify yourself that the electrical installation of the place you are working on follows the local safety rules and has a residual-current circuit breaker (RCCB) installed.
  • Never touch or handle the device when it's the mains AC power is on – always turn off the circuit breaker before connecting the wires or doing any manual configuration in the system.
  • This Nanoshield does not have safety devices like fuses or circuit breakers – you must install them externally according to the particular needs of your project.
  • If you want to include this module in a commercial product, check the requirements that are applicable to the safety certification processes in your area.

Downloads

Projects