Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

ESP32-Based Smart Home Automation System with Bluetooth Control

View and Edit Project In Cirkit DesignerImage of ESP32-Based Smart Home Automation System with Bluetooth Control

Circuit Documentation

Summary

This circuit is designed to control multiple AC bulbs and fans using an ESP32 microcontroller, a 4-channel relay module, and several flush switches. The circuit also includes an HC-05 Bluetooth module for wireless communication and a 5V adapter for power supply. The ESP32 microcontroller is programmed to control the relays based on the input from the flush switches and Bluetooth commands.

Component List

  1. ESP32

    • Description: A powerful microcontroller with built-in Wi-Fi and Bluetooth capabilities.
    • Pins: EN, VP, VN, D34, D35, D32, D33, D25, D26, D27, D14, D12, D13, GND, VIN, 3V3, D15, D2, D4, RX2, TX2, D5, D18, D19, D21, RX0, TX0, D22, D23, BOOT
  2. Relay 4 Channel 5v

    • Description: A relay module used to control high voltage devices like AC bulbs and fans.
    • Pins: GND, IN1, IN2, IN3, IN4, VCC, COM1, COM2, COM3, COM4, NO1, NO2, NO3, NO4, NC1, NC2, NC3, NC4
  3. HC-05 Bluetooth Module

    • Description: A Bluetooth module used for wireless communication.
    • Pins: Key, VCC, TXD, RXD, State, GND
  4. Flush Switch

    • Description: A simple switch used to provide input to the microcontroller.
    • Pins: GND, VCC
  5. AC Bulb

    • Description: A standard AC bulb.
    • Pins: P, N
  6. 5V Adapter

    • Description: A power adapter that converts AC to 5V DC.
    • Pins: AC In 1, AC In 2, 5V, GND
  7. AC Wall Plug Point

    • Description: A standard AC wall plug point.
    • Pins: E, N, L
  8. Fan

    • Description: A standard AC fan.
    • Pins: Neutral, Live
  9. Power 220V

    • Description: A 220V power source.
    • Pins: hot wire, neutral wire
  10. 9V Battery

    • Description: A standard 9V battery.
    • Pins: -, +

Wiring Details

ESP32

Relay 4 Channel 5v

HC-05 Bluetooth Module

Flush Switch

AC Bulb

5V Adapter

AC Wall Plug Point

Fan

Power 220V

Documented Code

ESP32 Code

void setup() {
  // put your setup code here, to run once:

}

void loop() {
  // put your main code here, to run repeatedly:

}

5V Adapter Code

void setup() {
  // put your setup code here, to run once:

}

void loop() {
  // put your main code here, to run repeatedly:

}

This documentation provides a comprehensive overview of the circuit, including the components used, their wiring details, and the code for the microcontrollers.