KY-019 Relay Module with Arduino

Introduction

The KY-019 5V relay module is a switch that can be used to control high voltage or high current circuits using a low voltage circuit. It is commonly used with an Arduino board to control devices such as motors, lights, and other appliances.

It is generally used in IoT projects to control lights and other electronic devices, It is also compatible to interfacing with Arduino, Raspberry Pi, ESP32, and other microcontrollers. to ON and OFF AC devices.

Hardware Required

You will require the following Hardware Components for the Interfacing of the KY-019 Relay Module with arduino.

Components#Buy From Amazon
Arduino UNO1Buy Link
KY-019 Relay Module1Buy Link
AC Bulb1Buy Link
Jumper WiresBuy Link
Breadboard1Buy Link

What is the KY-018 module?

A relay is an electrically operated switch that consists of a coil and one or more sets of contacts. When a current flows through the coil, it creates a magnetic field that causes the contacts to move and make or break a connection between two circuits. The contacts of a relay are often referred to as poles, and the state of the contacts is either normally open or normally closed.

KY-019-5V-Relay-Module-with-Arduino

Specifications

The KY-019 Includes a LED, a 1MΩ resistor, a 1N4007 rectifier diode, and a 5VDC relay capable of controlling up to 250VAC and 10A.

On the DC side of the Module, there are 3 male header pins for signal, power, and ground. On the AC side, there are 3 connections, NO (Normally Open) Common, and NC (Normally Closed).

TTL Control Signal5VDC to 12VDC (some boards may work with 3.3)
Maximum AC10A 250VAC
Maximum DC10A 30VDC
Contact TypeNC and NO
Board Dimensions27mm x 34mm [1.063in x 1.338in]

Pinout

KY-019-Relay-Module-Pinout-Diagram

The Normally Open (NO) contact is a type of contact that is open (not making contact) when the relay is not energized. When the relay is energized, the NO contact is closed, and current can flow through the circuit. The NO contact is used in applications where you want to interrupt the circuit when the relay is activated.

The Normally Closed (NC) contact is a type of contact that is closed (making contact) when the relay is not energized. When the relay is energized, the NC contact is opened, and the circuit is interrupted. The NC contact is used in applications where you want to maintain a connection between the circuits when the relay is not activated.

Pin Configuration

Pin NamePin Type
SSignal Pin
(+) MiddlePower Pin
( – )Ground Pin
NONormally Open
COMCommon
NCNormally Closed

Circuit Diagram

The following circuit shows you the connection of the KY-019 Relay Module with Arduino Please make the connection carefully

KY-019-5V-Relay-Module-Interfacing-with-Arduino-Circuit

Circuit Connections

Place the module on the Breadboard and connect the S (signal) Pin to pin 10 of the Arduino, also attach the Power line (+) and ground (-) to the +5 Pin and the GND Pin respectively.

ArduinoModule
Pin 10S
+5V(+) VCC
GND

Installing Arduino IDE Software

First, you will require to Download the updated version of Arduino IDE Software and Install it on your PC or laptop. if you Learn How to install the Arduino step-by-step guide then click on how to install Arduino Button given Blow

Code

//For more Projects: www.arduinocircuit.com
int relay = 10;  //Pin 10
void setup() 
{   
pinMode(relay,OUTPUT);     // Define the port attribute as output 
} 
void loop() 
{   
digitalWrite(relay,HIGH);  // turn the relay ON
			   // [NO] is connected to feed
			   // [NC] is not connected to feed
delay(1000);  				
digitalWrite(relay,LOW);   // turn the relay OFF
			   // [NO] is not connected to feed
			   // [NC] is connected to feed
delay(1000); 
}

Applications

  1. Home automation: Use the KY-019 relay module with an Arduino to automate your home’s lighting system, allowing you to turn lights on and off remotely or on a schedule.
  2. Motor control: Use the KY-019 relay module with an Arduino to control the speed and direction of DC motors, allowing you to create robotic projects or motorized vehicles.
  3. Security systems: Use the KY-019 relay module with an Arduino to trigger alarms or turn on lights when motion is detected by a sensor.
  4. Smart irrigation: Use the KY-019 relay module with an Arduino to control water pumps and valves for an automated irrigation system in your garden.
  5. Energy management: Use the KY-019 relay module with an Arduino to turn off appliances or lights automatically when they are not in use, helping to reduce energy consumption and save on electricity bills.

Leave a Comment


error: