Introduction: Wifi Smart Door(simplest Method)

About: I do robotics and automation projects.* denke anders!(think different!)

This is a simple project made with the arduino uno R3,the aim is to control a door lock without keys,and using a smart phone to accomplish this,the communication medium will be the internet(wifi module-ESP8266).

I have already posted an instructable about the same project with bluetooth module,you can refer it for any clarifications.(click here).

In this instructable you will be knowing about the simple IOT project of controlling the lock of your door with wifi module.

This is one of the simplest method to use ESP-8266.

Step 1: Collecting the Items Required

1.Arduino UNO R3

to control the servo and interface with the ESP 8266(GPIO pin-0 )

the concept is very simple we are going to control the ESP8266 (GPIO pin 0) from our smart phone with an app.

if GPIO -pin 0

LOW----------------------------------- lock state-closed.

HIGH-----------------------------------lock state-open.

the GPIO pin 0 state will be recognised by arduino using the digitalRead command and does the required operations on the Servo.

Step 2: ESP-8266 Wifi Module

This will help our project to get connected to the cloud.this is very cheap and easy to use.

In this project we will be using only the GPIO pin-0 of the ESP8266.

Step 3: High Torque Servo

to turn the lock lever when signal is sent from the arduino

it is powered by the arduino 5v pin itself and it works well with it.(only when the arduino is powered with usb cable)

Step 4: Sheet Metal

this is used to make the case for the servo motor which allows it to properly hold the motor on the door and the rotating part properly fixed to the lever of the lock.

the case is up to your creativity you can use any other material/thing to make the case. TO HOLD THE MOTOR ON THE DOOR

Step 5: 3.3V FTDI Programmer

This is used only in the making of the project,to program the ESP8266 module as it can't be programmed directly from arduino.

Step 6: Setup for ESP8266

You only need to establish a serial communication between your FTDI programmer and your ESP8266.

Connections:
RX -> TX

TX -> RX

CH_PD -> 3.3V

VCC -> 3.3V

GND -> GND

Step 7: Uploading Code to ESP(simplified Software)

using the ESPlorer IDE which is a program created by 4refr0nt to send commands to your ESP8266.

Follow these instructions to download and install ESPlorer IDE:

1.Click here to download ESPlorer

2.Unzip that folder

3.Go to the main folderRun “ESPlorer.jar” file

4.Open the ESPlorer IDE

5.Connect your FTDI programmer to your computer

6.Select your FTDI programmer port

7.Press Open/Close

8.Select NodeMCU+MicroPtyhon tab

9.Create a new file called init.lua
10.Press Save to ESP

11.Everything that you need to worry about or change is highlighted in red box.

12.Upload the following code into your ESP8266 using the preceding software. Your file should be named “init.lua“.

add your network name (SSID) and password to the script

ADD YOUR WIFI NETWORK NAME(SSID) AND PASSWORD TO THE SCRIPT

Your ESP IP Address
When your ESP8266 restarts, it prints in your serial monitor the ESP IP address. Save that IP address, because you’ll need it later.

Step 8: Coding the Arduino With IDE

I have given the coding you can download the file from here.

upload this code to the ARDUINO!

Attachments

Step 9: Inventing Your Own App

you can create one by your own by referring to the images provided above.

you can also download the app from here and install to your android phone.

It’s very easy to configure. Click the button “Set IP Address” on the bottom of the screen and type your IP address.

Step 10: The .aia File for the App

you can edit the app by using MIT app inventor website.(use import option)

Step 11: Assembly!

make sure the following connections are done.

SERVO CONNECTION
1.orange-----arduino pin 2

2.red-------5v pin in arduino

3.brown------ground pin in arduino

finally connect your ESP 8266 (GPIO pin 0) to digital pin 5 of the arduino.

ALL SET! IT's time to test your project and debug if any errors.

hope you like it !!!

REFERENCE:

I have referred the following website in the making and publishing of my project,

1. http://randomnerdtutorials.com/esp8266-controlled-with-android-app-mit-app-inventor/

Make It Move Contest 2017

Participated in the
Make It Move Contest 2017

Wireless Contest

Participated in the
Wireless Contest