Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use 2-CH relay: Examples, Pinouts, and Specs

Image of 2-CH relay
Cirkit Designer LogoDesign with 2-CH relay in Cirkit Designer

Introduction

The 2-Channel Relay Module (GM002), manufactured by PCBCIBID, is an electromechanical switch designed to control two independent circuits. This module allows low-power control signals, such as those from a microcontroller, to switch high-power devices like motors, lights, or appliances. It provides electrical isolation between the control circuit and the load, ensuring safety and reliability.

Explore Projects Built with 2-CH relay

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
WeMos D1 R2 Controlled Relay Switching Circuit for AC Bulb and USB Charger
Image of Hand Gesture Light: A project utilizing 2-CH relay in a practical application
This circuit uses a WeMos D1 R2 microcontroller to control a 5V 2-relay module, which in turn controls the power to an AC bulb and a cellphone charger. The microcontroller also interfaces with a line tracking sensor, which likely provides input to control the relay states. The AC bulb and cellphone charger are powered by an AC wire connection, with the relay acting as a switch for the bulb.
Cirkit Designer LogoOpen Project in Cirkit Designer
DC-DC Converter and Relay Module Power Distribution System
Image of relay: A project utilizing 2-CH relay in a practical application
This circuit consists of a DC-DC converter powering a 6-channel power module, which in turn supplies 5V to a 2-relay module. The power module distributes the converted voltage to the relay module, enabling it to control external devices.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32-Controlled Dual Relay Module
Image of ESP32 bluethooth with relay: A project utilizing 2-CH relay in a practical application
This circuit features an ESP32 microcontroller connected to a two-channel relay module. The ESP32's digital pins D25 and D26 are used to control the relay channels IN1 and IN2, respectively, allowing the microcontroller to switch external circuits on and off. The ESP32 and the relay module share a common ground and the ESP32's Vin pin supplies power to the relay's VCC, indicating that both operate at compatible voltage levels.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32 Wi-Fi Controlled Dual Relay Module
Image of esp: A project utilizing 2-CH relay in a practical application
This circuit features an ESP32 microcontroller connected to a two-channel 5V relay module. The ESP32 controls the relay channels via its GPIO pins D23 and D22, allowing it to switch external devices on and off. The relay module is powered by the 3.3V and GND pins of the ESP32.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with 2-CH relay

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of Hand Gesture Light: A project utilizing 2-CH relay in a practical application
WeMos D1 R2 Controlled Relay Switching Circuit for AC Bulb and USB Charger
This circuit uses a WeMos D1 R2 microcontroller to control a 5V 2-relay module, which in turn controls the power to an AC bulb and a cellphone charger. The microcontroller also interfaces with a line tracking sensor, which likely provides input to control the relay states. The AC bulb and cellphone charger are powered by an AC wire connection, with the relay acting as a switch for the bulb.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of relay: A project utilizing 2-CH relay in a practical application
DC-DC Converter and Relay Module Power Distribution System
This circuit consists of a DC-DC converter powering a 6-channel power module, which in turn supplies 5V to a 2-relay module. The power module distributes the converted voltage to the relay module, enabling it to control external devices.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of ESP32 bluethooth with relay: A project utilizing 2-CH relay in a practical application
ESP32-Controlled Dual Relay Module
This circuit features an ESP32 microcontroller connected to a two-channel relay module. The ESP32's digital pins D25 and D26 are used to control the relay channels IN1 and IN2, respectively, allowing the microcontroller to switch external circuits on and off. The ESP32 and the relay module share a common ground and the ESP32's Vin pin supplies power to the relay's VCC, indicating that both operate at compatible voltage levels.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of esp: A project utilizing 2-CH relay in a practical application
ESP32 Wi-Fi Controlled Dual Relay Module
This circuit features an ESP32 microcontroller connected to a two-channel 5V relay module. The ESP32 controls the relay channels via its GPIO pins D23 and D22, allowing it to switch external devices on and off. The relay module is powered by the 3.3V and GND pins of the ESP32.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications

  • Home automation systems (e.g., controlling lights or fans)
  • Industrial equipment control
  • Motor and pump control
  • IoT projects requiring high-power switching
  • Robotics and automation

Technical Specifications

Key Technical Details

  • Manufacturer: PCBCIBID
  • Part ID: GM002
  • Number of Channels: 2
  • Operating Voltage: 5V DC
  • Trigger Voltage: 3.3V to 5V (compatible with most microcontrollers)
  • Maximum Load Voltage: 250V AC or 30V DC
  • Maximum Load Current: 10A
  • Relay Type: SPDT (Single Pole Double Throw)
  • Isolation: Optocoupler-based isolation between control and load circuits
  • Dimensions: 50mm x 40mm x 18mm

Pin Configuration and Descriptions

The 2-CH relay module has two sets of pins: control pins and load terminals.

Control Pins

Pin Name Description
VCC Connect to the 5V power supply.
GND Connect to the ground of the power supply.
IN1 Control signal for Relay 1. A HIGH signal activates the relay.
IN2 Control signal for Relay 2. A HIGH signal activates the relay.

Load Terminals (for each relay)

Terminal Name Description
COM Common terminal for the relay.
NO Normally Open terminal. Connect the load here if it should be OFF by default.
NC Normally Closed terminal. Connect the load here if it should be ON by default.

Usage Instructions

How to Use the 2-CH Relay in a Circuit

  1. Power the Module:

    • Connect the VCC pin to a 5V DC power supply.
    • Connect the GND pin to the ground of the power supply.
  2. Connect the Control Signals:

    • Connect the IN1 and IN2 pins to the digital output pins of a microcontroller (e.g., Arduino UNO).
    • Ensure the control signals are within the 3.3V to 5V range.
  3. Connect the Load:

    • Identify the load you want to control (e.g., a light bulb or motor).
    • Connect one terminal of the load to the COM terminal of the relay.
    • Connect the other terminal of the load to either the NO or NC terminal, depending on the desired default state:
      • Use NO if the load should be OFF by default.
      • Use NC if the load should be ON by default.
  4. Control the Relay:

    • Send a HIGH signal (3.3V to 5V) to the IN1 or IN2 pin to activate the corresponding relay.
    • When the relay is activated, the COM terminal will connect to the NO terminal.

Important Considerations and Best Practices

  • Power Supply: Ensure the module is powered with a stable 5V DC supply.
  • Load Ratings: Do not exceed the maximum load voltage (250V AC or 30V DC) or current (10A).
  • Isolation: The module provides optocoupler-based isolation, but additional safety measures (e.g., fuses) are recommended for high-power applications.
  • Inductive Loads: When switching inductive loads (e.g., motors), use a flyback diode across the load to prevent voltage spikes.
  • Microcontroller Compatibility: The module is compatible with 3.3V and 5V logic levels, making it suitable for most microcontrollers, including Arduino, Raspberry Pi, and ESP32.

Example: Connecting to an Arduino UNO

Below is an example of how to control the 2-CH relay module using an Arduino UNO.

Circuit Diagram

  • Connect the VCC pin of the relay module to the 5V pin of the Arduino.
  • Connect the GND pin of the relay module to the GND pin of the Arduino.
  • Connect the IN1 and IN2 pins of the relay module to digital pins 7 and 8 of the Arduino, respectively.

Arduino Code

// Define the control pins for the relays
const int relay1 = 7; // Relay 1 connected to digital pin 7
const int relay2 = 8; // Relay 2 connected to digital pin 8

void setup() {
  // Set the relay pins as outputs
  pinMode(relay1, OUTPUT);
  pinMode(relay2, OUTPUT);

  // Initialize both relays to OFF state
  digitalWrite(relay1, LOW); // Relay 1 OFF
  digitalWrite(relay2, LOW); // Relay 2 OFF
}

void loop() {
  // Turn Relay 1 ON and Relay 2 OFF
  digitalWrite(relay1, HIGH); // Relay 1 ON
  digitalWrite(relay2, LOW);  // Relay 2 OFF
  delay(2000); // Wait for 2 seconds

  // Turn Relay 1 OFF and Relay 2 ON
  digitalWrite(relay1, LOW);  // Relay 1 OFF
  digitalWrite(relay2, HIGH); // Relay 2 ON
  delay(2000); // Wait for 2 seconds
}

Troubleshooting and FAQs

Common Issues and Solutions

  1. Relay Not Activating:

    • Cause: Insufficient control signal voltage.
    • Solution: Ensure the control signal is within the 3.3V to 5V range.
  2. Load Not Switching:

    • Cause: Incorrect wiring of the load terminals.
    • Solution: Verify the connections to the COM, NO, and NC terminals.
  3. Module Overheating:

    • Cause: Exceeding the maximum load current or voltage.
    • Solution: Ensure the load does not exceed 10A or 250V AC/30V DC.
  4. Interference with Microcontroller:

    • Cause: Voltage spikes from inductive loads.
    • Solution: Use a flyback diode across the load to suppress voltage spikes.

FAQs

  • Q: Can I use this module with a 3.3V microcontroller like ESP32?
    A: Yes, the module is compatible with 3.3V logic levels.

  • Q: Can I control DC motors with this relay?
    A: Yes, but ensure the motor's voltage and current are within the relay's ratings.

  • Q: Is the module safe for high-power applications?
    A: Yes, but additional safety measures, such as fuses and proper insulation, are recommended.

  • Q: Can I use both relays simultaneously?
    A: Yes, both relays can operate independently and simultaneously.

This concludes the documentation for the 2-CH Relay Module (GM002).