• Home
  • pcDuino
  • WiKi
  • Store
  • Distributors
  • Home
  • pcDuino
  • WiKi
  • Store
  • Distributors
HomeArduinoRelay Shield For Arduino
Previous Next

Relay Shield For Arduino

Posted by: admin , March 27, 2014

[vc_row][vc_column][vc_column_text]图片1

The Relay Shield is an Arduino compatible smart module with 4 mechanical relays providing an easy way to control high voltage. The max switching power is 35VDC 70W for each channel. It can be directly controlled by Arduino through digital IOs with external 9V DC supply.[/vc_column_text][vc_tour][vc_tab title=”Introduction” tab_id=”1395286962-1-3″][vc_column_text]

Features

  • Arduino, Arduino Mega compatible
  • 4 mechanical relays with photo-coupled circuit
  • Equipped with screw holes for easy installation
  • Light weight
  • Small form factor
  • Native Arduino compatibility
  • Extendible

Specification

图片2

Interface

图片3

[/vc_column_text][/vc_tab][vc_tab title=”Parts List” tab_id=”1395286962-2-22″][vc_column_text]

  1. 1  x[bigcommerce link=”/cityduino-arduino-uno-compatible-device/” target=”_blank”] Arduino UNO [/bigcommerce]
  2. 1  x  Relay Shield
  3. 1  x  9V DC wall adapter
  4. 2  x   LED
  5. 2  x  560 Ω Resistor
  6. 4  x  Jumper wires

[/vc_column_text][/vc_tab][vc_tab title=”Wiring Diagram” tab_id=”1395287127748-2-10″][vc_column_text]图片5图片4[/vc_column_text][/vc_tab][vc_tab title=”Test Code” tab_id=”1395287128772-3-8″][vc_column_text]

int relayPin[4] = {4,5,6,7};

void setup()
{
  int i;
  for(i = 0; i < 4; i++)
  {
    pinMode(relayPin[i],OUTPUT);
  }
}

//just an simple demo to close and open 4 relays
// every other 1s.
void loop()
{
  int i=0;
  for(i = 0; i < 4; i++)
  {
    digitalWrite(relayPin[i],HIGH);
  }
  delay(1000);
  for(i = 0; i < 4; i++)
  {
    digitalWrite(relayPin[i],LOW);
  } 
  delay(1000); 
}

[/vc_column_text][/vc_tab][vc_tab title=”Test Result” tab_id=”1395287129695-4-8″][vc_column_text]1. Wiring per the wiring diagram. The following is the picture of the whole setup:

图片5

2. Power on the Arduino, open the Arduino IDE, input test code, compile and load to Arduino:

图片6

3.  Power with 9V DC, we can see the two LED flash every one second.

图片7

图片8[/vc_column_text][/vc_tab][/vc_tour][/vc_column][/vc_row]

Tags: Arduino

Share!
Tweet

admin

About the author

Leave a Reply Cancel reply

You must be logged in to post a comment.

Category

  • Home
  • pcDuino
  • WiKi
  • Store
  • Distributors