Wednesday, 16 September 2015

Voice controlled smart home

Heyyyy all..!! again iam back with new prototype of thing which is "VOICE CONTROLLEd SMART HOME"in this post you are going to learn complete detailed description of Bluetooth module (HC-05) and also some micelinious already explained in earlier posts

Things that you need are:
 *Arduino board
*HC-05 Bluetooth module
*Relays ( as many as home appliances)

So our main aim is  to interface the Bluetooth module to our deserved one i.e ARDUINO
Here I made my own ARDUINO with atmega328p as heart also I programmed this board using another ARDUINO board which has onchip ftdi converter(USB compatible)
I hope you will understand this becoz I have given a clear theory about making ARDUINO'S

Interfacing of Bluetooth module with ARDUINO is very easy. Hc-05 module as total 6 terminals so out of six we are using only 3 terminals they are VCC,GND, and TX.remember there is no need of using RX pin of module because we are not receiving any data from ARDUINO. So VCC is connected to 3.3v since its operating voltage is 3.3v.if you don't have 3.3v supply simply connect it to GND is GND of ARDUINO
Important thing is TX of module should be connected to RX of the controller

Now it's time to connect output devices confused?? Here my output devices are relays because they are hleping in the switching operation.if I connect relay directly to the ARDUINO it won't work since relay is a inductive load..I need more current to drive relay so here iam using external supply for that.what about the controlling of relays if I connect them to external supply. The controlling is achieved by relay driver nothing but a transistor.input of the driver is connected to controller,output part is connected to relays and it is powered with some external means..So remaining thing is programming which is very interesting but before entering to programming we have to know the things occurring behind the Bluetooth module

Bluetooth module working
First download the app to your smartphone which is freely available in playstore. After installing the app open and pair your smart phone with the module,at the time of pairing if it asks any password type 0000 or 1234 which is default one.every smart phone contains one Bluetooth module and voie recognization circuit so we are using these two things as exploits to hack our thing. Here I program the controller such that if it receives any string it should acivate the relays.  some commands I used in program are LIGHT ON,LIGHT OFF,FAN ON ,FAN OFF ETC.

Below is the code which is written in ARDUINO ide

String voice;
void setup()
void loop()
  if(voice=="*light on")
  else if(voice=="*light off")
  else if(voice=="*fan on")
  else if(voice=="*fan off")

  Here some of pics...