ablab

Hello Readers, welcome to my Blog - A Blog For Bloggers By A Blogger. I'm Arun, an entrepreneur Blogger from India.

Relay and HC-05 Bluetooth based Android Mobile Controlled Wireless Home Automation System with ATmega16-I

14718
5
Mark as Favourite

In this project, we will learn How to design a relay and HC-05 Bluetooth based Android Mobile controlled wireless Home Automation system with AVR ATmega16 microcontroller Part-I. Here, we will use the Android Mobile as the input device to control the appliances i.e 2 bulbs and 2 fans wirelessly.

The communication between HC-05 Bluetooth Module and Android Mobile takes place through wireless Bluetooth technology. And the communication between HC-05 Bluetooth Module and ATmega16 microcontroller takes place through UART serial communication protocol. The HC-05 Bluetooth Module and Android Mobile are connected through Bluetooth. User enters the control signal from Android Mobile through Bluetooth Terminal App and the Android Mobile transmits the control signal to the HC-05 Bluetooth Module through its bluetooth. The HC-05 Bluetooth Module receives the control signal and transmits it to the ATmega16 microcontroller through UART.

The ATmega16 microcontroller receives the control signal and processes it and sends the required control signal to the Relay Driver. Relay Driver will turn On or Off the home appliances according the control signal received from the ATmega16 microcontroller. The ATmega16 microcontroller also sends the appliance status to the Android Mobile through bluetooth.

Here, we will use 2 keys from the Android Mobile to control one appliance. One key will be used to turn on and the other key will be used to turn off the appliance. So, for four appliances, we will use 8 keys from Android Mobile. Apart from these 8 keys, we will use 2 more keys to turn on and off all appliances at a time. Now, press different keys from the Android Mobile and control the appliances as you want.

Control Keys

Appliance Status Change

1

Appliance 1 On

2

Appliance 1 Off

3

Appliance 2 On

4

Appliance 2 Off

5

Appliance 3 On

6

Appliance 3 Off

7

Appliance 4 On

8

Appliance 4 Off

9

All Appliances On

0

All Appliances Off

Softwares Required

Hardwares Required

Name Quantity
AVR Trainer Board-100 with ATmega16 1pc
AVR USB Programmer 1pc
12V, 1A DC SMPS Adaptor 1pc
Quad Relay Driver 1pc
HC-05 Bluetooth Board 1pc
Home Appliance Board 1pc
1 to 1 Connector-Female to Female 10pc
10 to 10 FRC Female to Female Connector 1pc

Circuit Diagram

Video

Connection Guide

The step-by-step connection guide for Relay and HC-05 Bluetooth based Android Mobile Controlled Wireless Home Automation System with ATmega16-I is as follows

  • Steps - 1 ( 0f 17 )

    Insert the DC Pin of 12V, 1A DC Adapter to the DC Socket of AVR Trainer Board-100.

  • Steps - 2 ( 0f 17 )

    Connect the 12V and GND pins of Relay Control header of Quad Relay Driver with the 12V and GND pins of 12V and GND header of AVR Trainer Board-100 with 1 to 1 Connectors.

  • Steps - 3 ( 0f 17 )

    Connect the A1, A2, A3 and A4 pins of Relay Control header of Quad Relay Driver with PB0, PB1, PB2 and PB3 pins of PORTB header of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

  • Steps - 4 ( 0f 17 )

    Connect the Neutral and Phase of AC Supply from Wall to N and PH of AC Input Terminal Blocks of Quad Relay Driver with wires.

  • Steps - 5 ( 0f 17 )

    Connect the Neutrals of 2 Bulbs and 2 Fans to the N pin of AC Output Terminal Blocks of Quad Relay Driver with wires.

  • Steps - 6 ( 0f 17 )

    Connect the Phases of 2 Bulbs and 2 Fans to the PH1, PH2, PH3 and PH4 pins of AC Output Terminal Blocks of Quad Relay Driver respectively with wires.

  • Steps - 7 ( 0f 17 )

    Connect the VCC and GND pins of HC-05 Bluetooth Module with the 5V(VCC) and GND header pins of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

  • Steps - 8 ( 0f 17 )

    Connect the TXD and RXD pins of HC-05 Bluetooth Module with PD0 and PD1 pins of PortD header of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

  • Steps - 9 ( 0f 17 )

    Connect the ISP header of AVR Trainer Board-100 with AVR USB Programmer header of AVR USB Programmer with a 10 to 10 FRC Female Connector.

  • Steps - 10 ( 0f 17 )

    Connect the AVR USB Programmer to the PC/Laptop's USB Port directly or with the help of USB AM-AF Cable.

  • Steps - 11 ( 0f 17 )

    Download Relay and HC-05 Bluetooth based Android Mobile Controlled Wireless Home Automation System with ATmega16-I

  • Steps - 12 ( 0f 17 )

    Hex file to AVR Trainer Board-100 with the help of SinaProg Hex downloader and AVR USB Programmer.

  • Steps - 13 ( 0f 17 )

    Switch on the power with the help of Power Switch of AVR Trainer Board-100.

  • Steps - 14 ( 0f 17 )

    Pair the HC-05 Bluetooth Module with Android Mobile. Default PIN of HC-05 is 1234.

  • Steps - 15 ( 0f 17 )

    Open the Bluetooth Terminal App in the Mobile and Connect the HC-05 Bluetooth Module with it.

  • Steps - 16 ( 0f 17 )

    Reset the AVR Trainer Board-100 using its Reset switch.

  • Steps - 17 ( 0f 17 )

    Press different keys from Mobile Keypad and see the output.

  • Insert the DC Pin of 12V, 1A DC Adapter to the DC Socket of AVR Trainer Board-100.

    Steps - 1 ( 0f 17 )

  • Connect the 12V and GND pins of Relay Control header of Quad Relay Driver with the 12V and GND pins of 12V and GND header of AVR Trainer Board-100 with 1 to 1 Connectors.

    Steps - 2 ( 0f 17 )

  • Connect the A1, A2, A3 and A4 pins of Relay Control header of Quad Relay Driver with PB0, PB1, PB2 and PB3 pins of PORTB header of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

    Steps - 3 ( 0f 17 )

  • Connect the Neutral and Phase of AC Supply from Wall to N and PH of AC Input Terminal Blocks of Quad Relay Driver with wires.

    Steps - 4 ( 0f 17 )

  • Connect the Neutrals of 2 Bulbs and 2 Fans to the N pin of AC Output Terminal Blocks of Quad Relay Driver with wires.

    Steps - 5 ( 0f 17 )

  • Connect the Phases of 2 Bulbs and 2 Fans to the PH1, PH2, PH3 and PH4 pins of AC Output Terminal Blocks of Quad Relay Driver respectively with wires.

    Steps - 6 ( 0f 17 )

  • Connect the VCC and GND pins of HC-05 Bluetooth Module with the 5V(VCC) and GND header pins of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

    Steps - 7 ( 0f 17 )

  • Connect the TXD and RXD pins of HC-05 Bluetooth Module with PD0 and PD1 pins of PortD header of AVR Trainer Board-100 respectively with 1 to 1 Connectors.

    Steps - 8 ( 0f 17 )

  • Connect the ISP header of AVR Trainer Board-100 with AVR USB Programmer header of AVR USB Programmer with a 10 to 10 FRC Female Connector.

    Steps - 9 ( 0f 17 )

  • Connect the AVR USB Programmer to the PC/Laptop's USB Port directly or with the help of USB AM-AF Cable.

    Steps - 10 ( 0f 17 )

  • Download Relay and HC-05 Bluetooth based Android Mobile Controlled Wireless Home Automation System with ATmega16-I

    Steps - 11 ( 0f 17 )

  • Hex file to AVR Trainer Board-100 with the help of SinaProg Hex downloader and AVR USB Programmer.

    Steps - 12 ( 0f 17 )

  • Switch on the power with the help of Power Switch of AVR Trainer Board-100.

    Steps - 13 ( 0f 17 )

  • Pair the HC-05 Bluetooth Module with Android Mobile. Default PIN of HC-05 is 1234.

    Steps - 14 ( 0f 17 )

  • Open the Bluetooth Terminal App in the Mobile and Connect the HC-05 Bluetooth Module with it.

    Steps - 15 ( 0f 17 )

  • Reset the AVR Trainer Board-100 using its Reset switch.

    Steps - 16 ( 0f 17 )

  • Press different keys from Mobile Keypad and see the output.

    Steps - 17 ( 0f 17 )

Downloads

Relay and HC-05 Bluetooth based Android Mobile Controlled Wireless Home Automation System with ATmega16-I
  • 45 downloads 0 Kb

Post a Comment

    • Lakshan
      how to recognize the values of components? ex. relay,resistor,etc. answer asap
      2016-12-18 12:16:55
      Reply
    • SourinAhmed
      cant run the .c file...please help
      2017-05-08 15:36:20
      Reply
    • mostafa
      linkesh koo? |:
      2017-08-31 19:25:17
      Reply
    • AnilThomas
      can you please send me the code
      2017-08-19 14:34:21
      Reply
    • jajabageur
      mantap
      2019-06-11 16:44:47
      Reply