Skip to content

Two Channel Time Controlled Relay Two Channel Time Controlled Relay Circuit Using Arduino and RTC

This article explains how to build a Two Channel Time Controlled Relay circuit using Arduino, relays, RTC, LCD, transistors, and supporting components. The Two Channel Time Controlled Relay is a hardware-based automation project that switches two devices ON and OFF at specific times. The Two Channel Time Controlled Relay project uses a real-time clock for accurate scheduling and an LCD for display. The Two Channel Time Controlled Relay circuit includes relays controlled by BC547 transistors, diodes, and resistors.

This Two Channel Time Controlled Relay project provides a complete bill of materials with buy links. The Two Channel Time Controlled Relay circuit diagram and connections are explained in detail. The Two Channel Time Controlled Relay project helps beginners learn relay interfacing with Arduino. Building a Two Channel Time Controlled Relay is simple and efficient with basic electronic components.


Introduction

Automation has become an essential part of modern electronics. One of the simplest yet powerful automation circuits is a Two Channel Time Controlled Relay, which allows you to control two separate loads (appliances, devices, or systems) based on a time schedule.

This project is strictly hardware-focused. It uses an Arduino board, an RTC (real-time clock) module for accurate timekeeping, an LCD to display information, and two relays controlled by transistors and supporting components.

The Two Channel Time Controlled Relay is particularly useful for controlling devices where manual switching is not desirable, or when precise timing is required.


 Materials for the Project

S.NoComponentQuantityDescriptionBuy Link
1Arduino Uno/Nano1Microcontroller board for relay controlBuy
2Relay (5V SPDT)2Electromagnetic relay for switchingBuy
3BC547 Transistor2NPN transistor for relay drivingBuy
4Resistor 1kΩ2Base current limiting resistorBuy
5Diode 1N41482Flyback diode for relay protectionBuy
6Terminal Block 2-pin3For load and power connectionsBuy
7Push Button3For manual setting inputBuy
8LCD 16×2 with I2C1For displaying time and relay statusBuy
9RTC Module (DS3231/DS1307)1Real-time clock for timing accuracyBuy
10PCB or Breadboard1For assembling the circuitBuy
11Connecting WiresAs requiredFor circuit wiringBuy

Useful Tools 

ToolQuantityPurpose / NotesClick & Buy
Soldering Iron Kit1For making permanent connectionsClick & Buy
Solder Wire (60/40, 0.8mm)1Electrical solderingClick & Buy
Wire Stripper & Cutter1Stripping jumper wiresClick & Buy
Mini Screwdriver Set1For module and relay terminal screwsClick & Buy
Multimeter1Testing voltages and continuityClick & Buy
Hot Glue Gun (optional)1Securing components in placeClick & Buy
Small Pliers1Holding and bending wiresClick & Buy
Heat Shrink Tubing Set1Insulating exposed wiresClick & Buy

Circuit Diagram Explanation

The Two Channel Time Controlled Relay circuit is designed around Arduino, which acts as the central controller. The RTC module keeps track of time, ensuring accuracy. Relays act as the switching devices, controlled by BC547 transistors. Here’s a detailed explanation:

  • Power Supply: A two-pin terminal block connects the Arduino 5V and GND to power the circuit.

  • Relay Driver Stage:

    • Each relay is driven by a BC547 transistor.

    • A 1kΩ resistor connects the Arduino digital pin (D3 for relay 1, D4 for relay 2) to the transistor base.

    • The transistor collector connects to one end of the relay coil.

    • The other coil end connects to Arduino 5V.

    • A 1N4148 diode is placed across the relay coil to suppress back EMF.

  • Relay Load Terminal:

    • A terminal block connects the relay COM and NO pins, where external devices can be wired.

  • Push Buttons: Three push buttons are added to D5, D6, and D7 with pull-down to GND for manual input (e.g., time set, relay toggle).

  • Display: The LCD (16×2 with I2C module) connects to Arduino via SDA (A4) and SCL (A5).

  • RTC Module: Also connected to SDA (A4) and SCL (A5), sharing the I2C bus with the LCD.

This simple configuration allows two devices to be independently controlled based on time.

Download Circuit Diagram

Two Channel Time Controlled Relay Circuit Diagram
9/21/2025

Step-by-Step Hardware Connections

Follow these steps carefully to assemble the Two Channel Time Controlled Relay:

Step 1: Power Supply Setup

  • Connect a two-pin terminal block.

  • Connect one pin to Arduino 5V and the other pin to GND.

Step 2: First Relay Driver Circuit

  • Place BC547 transistor, connect emitter (pin 3) to GND.

  • Connect a 1kΩ resistor from Arduino pin D3 to base (pin 2).

  • Connect collector (pin 1) to one relay coil terminal.

  • Connect the other relay coil terminal to 5V.

  • Place a 1N4148 diode across the relay coil (cathode to 5V, anode to transistor collector).

  • Connect relay COM and NO to a terminal block for load connection.

Step 3: Second Relay Driver Circuit

  • Place another BC547 transistor, connect emitter (pin 3) to GND.

  • Connect a 1kΩ resistor from Arduino pin D4 to base (pin 2).

  • Connect collector (pin 1) to one relay coil terminal.

  • Connect the other relay coil terminal to 5V.

  • Place a 1N4148 diode across the relay coil (cathode to 5V, anode to collector).

  • Connect relay COM and NO to a terminal block for load connection.

Step 4: Push Buttons

  • Button 1: Connect one side to D5, other side to GND.

  • Button 2: Connect one side to D6, other side to GND.

  • Button 3: Connect one side to D7, other side to GND.

Step 5: LCD Display (16×2 with I2C)

  • VCC → 5V

  • GND → GND

  • SDA → A4

  • SCL → A5

Step 6: RTC Module (DS3231/DS1307)

  • VCC → 5V

  • GND → GND

  • SDA → A4

  • SCL → A5

At this stage, the wiring is complete.

Step 7: Assembly

After making all the connections, I designed a PCB for this project. Then, I placed all the components onto the PCB, soldered them, and completed the circuit.

Gerber Files 

Step 8: Final Step

Now, upload the Arduino code to control the relays with real-time scheduling. Once uploaded, the relays will automatically switch ON/OFF based on the set times.

Arduino Code     


PCB Assembly

For permanent installation, a PCB can be designed. The PCB layout should have clear tracks for:

  • Arduino power lines

  • Relay driver circuits

  • Diode protection paths

  • RTC and LCD I2C bus routing

  • Terminal blocks for external load connections

After soldering all components onto the PCB, double-check connections for shorts or errors.


Working Principle

The RTC continuously keeps track of time. Arduino reads this time and decides when to activate or deactivate the relays.

  • When the set time matches the internal clock, Arduino outputs a HIGH signal on the corresponding pin (D3 or D4).

  • The HIGH signal drives the BC547 transistor into saturation, energizing the relay coil.

  • The relay switches from COM to NO, turning the connected device ON.

  • When time is over, Arduino turns the pin LOW, de-energizing the relay and switching OFF the load.

The LCD display keeps showing the time and relay status.


Testing the Circuit

  1. Assemble the hardware on a breadboard or PCB.

  2. Power up the Arduino via USB or regulated 5V supply.

  3. The LCD should initialize and display the current time.

  4. Observe the relays clicking ON/OFF as per the pre-set timing.

  5. Use the push buttons to manually test relay toggling or adjust time settings.


Advantages of the Design

  • Two independent channels for device control

  • Uses reliable RTC module for accurate timing

  • Relay isolation for safe switching of higher loads

  • Easy to expand for more channels

  • Compact PCB assembly possible


Frequently Asked Questions (FAQs)

1. What is a Two Channel Time Controlled Relay?

It is a circuit that controls two relays (and thus two devices) based on pre-defined time intervals using Arduino and RTC.

2. Why do we use BC547 transistors in this circuit?

Relays require more current than Arduino pins can supply. BC547 transistors act as drivers, amplifying current to energize the relay coils.

3. What is the purpose of the 1N4148 diodes?

They protect the circuit from voltage spikes generated by relay coil switching (flyback effect).

4. Can I increase the number of channels?

Yes, by replicating the transistor–relay driver stage and assigning additional Arduino pins, you can add more channels.

5. Do I need a separate power supply for the relays?

For small relays (5V, low current), Arduino 5V is sufficient. For larger relays, use an external regulated 5V supply with common ground.

6. Why is the RTC necessary?

Arduino alone cannot keep accurate time after power loss. The RTC has a backup battery and ensures reliable timekeeping.

7. Can I build this without PCB?

Yes, it can be built on a breadboard or perfboard for testing, but PCB ensures durability and clean wiring.


Conclusion

The Two Channel Time Controlled Relay project is an excellent way to learn about relay driving, transistor interfacing, and time-based automation. The hardware-only approach makes it easy to assemble without diving into coding details.

By carefully following the step-by-step guide, wiring the circuit, and assembling components on a PCB, you can successfully build your own Two Channel Time Controlled Relay system for reliable timed control.

Leave a Reply

Your email address will not be published. Required fields are marked *