Handson Technology. 2 Channel 5V Optical Isolated Relay Module. User Guide. 1

Similar documents
4 CHANNEL 5V RELAY MODULE

L298N Dual H-Bridge Motor Driver

UNIT 9: RELAYS WHAT IS A RELAY (PRINCIPLE OF OPERATION)?

9 Output Devices: Buzzers

If I wanted to connect an LED and little light bulb and have them switch on and off with one switch, my schematic would look like the one below.

Product Manual. Relay Plug

Basic Electronics and Raspberry Pi IO Programming

PLCIO2 Programmable Logic Controller Updated 3/26/10

8:1 Serial Port Expander

3. The circuit is composed of 1 set of Relay circuit.

Motor Controller Cooling System (MCCS) Maintenance Manual

Raspberry Pi Activity 2: My Binary Addiction...Reloaded

keyestudio Keyestudio MEGA 2560 R3 Board

Joy-IT Ultrasonic Distance Sensor

Laboratory 1 Introduction to the Arduino boards

ARDUINO MICRO WITHOUT HEADERS Code: A000093

ARDUINO LEONARDO WITH HEADERS Code: A000057

Custard Pi 5 - Breakout board with protection for 8 digital I/O and stacking connector for the Raspberry Pi GPIO

TWO PLAYER REACTION GAME

Arduino Uno. Arduino Uno R3 Front. Arduino Uno R2 Front

How to Use an Arduino

PN PSTK-120 PowerSwitch Tail 120vac Kit PN PSTK-240 PowerSwitch Tail 240vac Kit

ARDUINO LEONARDO ETH Code: A000022

CHAPTER 1.0: INTRODUCTION TO AUTOMATION SYSTEM

SF Innovations Ltd. User Instructions (5th January 2016) Contents. Introduction

Alarm Circuits Explained. A Guide to Inputs and Outputs Used in Video Security

User's Manual. For ST-6560V3. Version All Rights Reserved

CamJam EduKit Sensors Worksheet Five. Equipment Required. The Parts. The Passive Infrared Sensor

Alessandra de Vitis. Arduino

RASPBERRY PI MEGA-IO EXPANSION CARD USER'S GUIDE VERSION 2.3

ARDUINO M0 PRO Code: A000111

ARDUINO YÚN Code: A000008

SF Innovations Ltd. Custard Pi 3-8 Analogue input board for the Raspberry Pi GPIO. User Instructions (13th December 2016) Contents.

Electronics Single Board Computers

WS2812B RGB LED Strip

Trigger I/O Board for the LogiComm Gun Driver

Bluetooth Based Home Automation Using Arduino and Android Application

ARDUINO MEGA ADK REV3 Code: A000069

ARDUINO UNO REV3 Code: A000066

ARDUINO MEGA 2560 REV3 Code: A000067

Arduino ADK Rev.3 Board A000069

ARDUINO UNO REV3 SMD Code: A The board everybody gets started with, based on the ATmega328 (SMD).

DAQCplate Users Guide

Grove - Buzzer. Introduction. Features

KMTRONIC LTD. Relay Controller Model C2R5 User Guide

Appendix F: Design Documentation for multisensory therapy system

Arduino Dock 2. The Hardware

Contents. Please read and remember the following warnings before using the RELAYplate:

MAE106 Laboratory Exercises Lab # 1 - Laboratory tools

BILLING AND CONTROLLING OF INDIVIDUAL LOADS OF A COMPOSITE SYSTEM USING SIMPLE ANDROID APPLICATION

ARDUINO INDUSTRIAL 1 01 Code: A000126

PLCADD1616 User Guide 3/29/10. Overview

ARDUINO UNO R3 BASED 20A ROBOT CONTROL BOARD [RKI-1580] Page 1

PCLD-8751 PCLD User Manual

INSTALLATION MANUAL. LC 200 Electronic Overload Guard. Software versione PW0501 R 0.3

USER S MANUAL VER.2. C76- MULTIFUNCTION CNC BOARD Rev. 1.4

Note. The above image and many others are courtesy of - this is a wonderful resource for designing circuits.

Stellar Instruments. SC1 Controller & Display System. General User s Manual. Copyright 2013 Stellar Instruments 1

Introduction to Internet of Things Prof. Sudip Misra Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur

4x4 Matrix Membrane Keypad

Intel Galileo gen 2 Board

The E and M signals define where the signal originates. The naming had its origins in telephony.

Modtronix Engineering Modular Electronic Solutions SBC28DC. Single board computer for 28 pin DIP PICs

Lab 01 Arduino 程式設計實驗. Essential Arduino Programming and Digital Signal Process

P16105: CubeSat Attitude Determination Control System (ADCS) Testing Apparatus Presents

Introduction to Arduino. Wilson Wingston Sharon

GPIO CONFIGURATION. Screen Touch-Pads <LOCAL RACK> Selects the GPIO in the Local Rack (16 GPIO channels).

UNIPORT V2. Uniport V2

Release Note. How to Use the OptoCon Connection Module. 1 Introduction. Option C Revision 4 Revised 8/13/98

Digital I/O Operations

SOLAR ENERGY DRIVEN MOSQUITO REPELLER SYSTEM USING ARDUINO UNO

PP-BOB2-V1.0 PARALLEL PORT BREAKOUT BOARD

Omega MP. Multi-Programming Shield for Atmel Microcontrollers. User Manual

ACORN User Guide For Revision (Aka Acorn_rev3) Updated 1/23/17

OP /32 Digital Inputs User Guide.

RaRa Academy: Raspberry Pi. Karl Heinz Kremer - K5KHK

Grove - Magnetic Switch

SEAS Computing Facility Raspberry Pi Workshop 2: I/O Camera & Motion Sensor. October 21, 2017

CDN502 HIGH DENSITY I/O ADAPTER USER GUIDE

BrewTroller Phoenix. Owners Manual. Updated - March 14, 2016 BREWTROLLER PHOENIX 1

Getting Started with InnoSwitch TM 3-Pro Code Library using Arduino

USER S MANUAL. C11- MULTIFUNTCION CNC BOARD Rev. 9.9

Getting started with X-NUCLEO-53L1A1 long distance ranging ToF sensor expansion board based on VL53L1X for STM32 Nucleo

USB-I/O Manual. UHRO-16 - DIN-Rail-Version. UPRO-16 - Board-Version. 16 photo couple input / 16 relay output channels

!There are two kit models. The ZCTK-120 is designed to operate with.!the pulse output is isolated from the mains line voltage. A pull-up resistor

KK1L 2x6 Antenna Switch Relay Controller / Dual Band Decoder Basic Assembly Version 4.8 (new 24-Aug-2009) Parts List updated 19-AUG-2016

Preface About this User's Guide... iv What you will learn from this user's guide... iv Conventions in this user's guide... iv

USB I/O-CARD WITH 32 INPUTS

Prototyping & Engineering Electronics Kits Basic Kit Guide

CamJam EduKit Robotics Worksheet Four Driving & Turning camjam.me/edukit

Project Planning. Module 4: Practice Exercises. Academic Services Unit PREPARED BY. August 2012

Introduction to Arduino

Lab 2 - Powering the Fubarino. Fubarino,, Intro to Serial, Functions and Variables

Handson Technology. HC-SR04 Ultrasonic Sensor Module. 1

ISO-DA16/DA8. Hardware Manual

Tu Sitio de Automatización!

Manual 601: : USB/RS232. Specifications. Contents. Options

Switching and controlling in the switch cabinet

XNUCLEO-F030R8, Improved STM32 NUCLEO Board

USER MANUAL ARDUINO I/O EXPANSION SHIELD

Transcription:

User Guide Handson Technology 2 Channel 5V Optical Isolated Relay Module This is a LOW Level 5V 2-channel relay interface board, and each channel needs a 15-20mA driver current. It can be used to control various appliances and equipment with large current. It is equipped with high-current relays that work under AC250V 10A or DC30V 10A. It has a standard interface that can be controlled directly by microcontroller. This module is optically isolated from high voltage side for safety requirement and also prevent ground loop when interface to microcontroller. Brief Data: Relay Maximum output: DC 30V/10A, AC 250V/10A. 2 Channel Relay Module with Opto-coupler. LOW Level Trigger expansion board, which is compatible with Arduino control board. Standard interface that can be controlled directly by microcontroller ( 8051, AVR, *PIC, DSP, ARM, ARM, MSP430, TTL logic). Relay of high quality low noise relays SPDT. A common terminal, a normally open, one normally closed terminal. Opto-Coupler isolation, for high voltage safety and prevent ground loop with microcontroller. 1 www.handsontec.com

Schematic: VCC and RY-VCC are also the power supply of the relay module. When you need to drive a large power load, you can take the jumper cap off and connect an extra power to RY-VCC to supply the relay; connect VCC to 5V of the MCU board to supply input signals. NOTES: If you want complete optical isolation, connect "Vcc" to Arduino +5 volts but do NOT connect Arduino Ground. Remove the Vcc to JD-Vcc jumper. Connect a separate +5 supply to "JD-Vcc" and board Gnd. This will supply power to the transistor drivers and relay coils. If relay isolation is enough for your application, connect Arduino +5 and Gnd, and leave Vcc to JD-Vcc jumper in place. It is sometimes possible to use this relay boards with 3.3V signals, if the JD-VCC (Relay Power) is provided from a +5V supply and the VCC to JD-VCC jumper is removed. That 5V relay supply could be totally isolated from the 3.3V device, or have a common ground if opto-isolation is not needed. If used with isolated 3.3V signals, VCC (To the input of the opto-isolator, next to the IN pins) should be connected to the 3.3V device's +3.3V supply. NOTE: Some Raspberry-Pi users have found that some relays are reliable and others do not actuate sometimes. It may be necessary to change the value of R1 from 1000 ohms to something like 220 ohms, or supply +5V to the VCC connection. 2 www.handsontec.com

NOTE: The digital input s from Arduino are Active LOW: The relay actuates and LED lights when the input pin is LOW, and turns off on HIGH. Module Layout: Operating Principle: See the picture below: A is an electromagnet, B armature, C spring, D moving contact, and E fixed contacts. There are two fixed contacts, a normally closed one and a normally open one. When the coil is not energized, the normally open contact is the one that is off, while the normally closed one is the other that is on. Supply voltage to the coil and some currents will pass through the coil thus generating the electromagnetic effect. So the armature overcomes the tension of the spring and is attracted to the core, thus closing the moving contact of the armature and the normally open (NO) contact or you may say releasing the former and the normally closed (NC) contact. After the coil is de-energized, the electromagnetic force disappears and the armature moves back to the original position, releasing the moving contact and normally closed contact. The closing and releasing of the contacts results in power on and off of the circuit. Input: VCC : Connected to positive supply voltage (supply power according to relay voltage) GND : Connected to supply ground. IN1: Signal triggering terminal 1 of relay module 3 www.handsontec.com

IN2: Signal triggering terminal 2 of relay module Output: Each module of the relay has one NC (normally close), one NO (normally open) and one COM (Common) terminal. So there are 2 NC, 2 NO and 2 COM of the channel relay in total. NC stands for the normal close port contact and the state without power. NO stands for the normal open port contact and the state with power. COM means the common port. You can choose NC port or NO port according to whether power or not. Testing Setup: When a low level is supplied to signal terminal of the 2-channel relay, the LED at the output terminal will light up. Otherwise, it will turn off. If a periodic high and low level is supplied to the signal terminal, you can see the LED will cycle between on and off. For Arduino: Step 1: Connect the signal terminal IN1 IN2 of 2-channel relay to digital pin 4 & 5 of the Arduino Uno or ATMega2560 board, and connect an LED at the output terminal. IN1> 4 IN2> 5 Step 2: Upload the sketch "text_code" to the Arduino Uno or ATMega2560 board.then you can see the LED cycle between on and off. The actual figure is shown below: For raspberry Pi: 4 www.handsontec.com

Step1: Connect the signal terminal IN2 IN1 of 2-channel relay to port 17 18 of the Raspberry Pi, and connect an LED at the output terminal. IN2 > 17 IN1 > 18 Step 2: Run the test_code. Then you can see the LED cycle between on and off. Sketch for Arduino: /************************************************ Name:_2_channel_relay Description: control the 2 channel relay module to ON or OFF Website: www.handsontec.com Email: techsupport@handsontec.com *****************************************************/ //the relays connect to int IN1 = 4; int IN2 = 5; #define ON 0 #define OFF 1 void setup() { relay_init();//initialize the relay void loop() { relay_setstatus(on, OFF);//turn on RELAY_1 5 www.handsontec.com

delay(2000);//delay 2s relay_setstatus(off, ON);//turn on RELAY_2 delay(2000);//delay 2s void relay_init(void)//initialize the relay { //set all the relays OUTPUT pinmode(in1, OUTPUT); pinmode(in2, OUTPUT); relay_setstatus(off, OFF); //turn off all the relay //set the status of relays void relay_setstatus( unsigned char status_1, unsigned char status_2) { digitalwrite(in1, status_1); digitalwrite(in2, status_2); Code for Raspberry Pi: #!/usr/bin/env python ''' ********************************************************************** * Filename : 2_channel_relay.py * Description : a sample script for 2-Channel High trigger Relay * E-mail : techsupport@handsontec.com * Website : www.handsontec.com * Detail : New file ********************************************************************** ''' import RPi.GPIO as GPIO from time import sleep Relay_channel = [17, 18] def setup(): GPIO.setmode(GPIO.BOARD) GPIO.setup(Relay_channel, GPIO.OUT, initial=gpio.low) print " ===================================================== " print " 2-Channel High trigger Relay Sample " print " ----------------------------------------------------- " print " Turn 2 channels on off in orders " print " 17 ===> IN2 " print " 18 ===> IN1 " print " ===================================================== " def main(): while True: for i in range(0, len(relay_channel)): print '...Relay channel %d on' % i+1 GPIO.output(Relay_channel[i], GPIO.HIGH) sleep(0.5) print '...Relay channel %d off' % i+1 GPIO.output(Relay_channel[i], GPIO.LOW) sleep(0.5) def destroy(): GPIO.output(Relay_channel, GPIO.LOW) GPIO.cleanup() 6 www.handsontec.com

if name == ' main ': setup() try: main() except KeyboardInterrupt: destroy() 7 www.handsontec.com