Introduction: Wifi Smart Door(simplest Method)

Picture of Wifi Smart Door(simplest Method)

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

Picture of 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

Picture of 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

Picture of 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

Picture of 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

Picture of 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

Picture of 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)

Picture of 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

Picture of Coding the Arduino With IDE

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

upload this code to the ARDUINO!

Step 9: Inventing Your Own App

Picture of 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!

Picture of 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/

Comments

JonnyMac (author)2017-11-11

I'm curious as to why these projects require connection to an external network. Is it not possible to use the ESP8266 as an access point? Wouldn't this allow for wifi connection to it in places where another network is not available?

nogueira (author)2017-11-06

Would you shave the APP Inventor source?

XTL (author)nogueira2017-11-07

Looks like it's on his blog page here as an aia file:

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

nogueira (author)XTL2017-11-07

Yes, my bad, sorry

einzigartig arun made it! (author)nogueira2017-11-07

This is the .aia format of the app you can change or edit it by importing it using MIT app inventor website.

Perfect! Thank you very much

nogueira (author)2017-11-07

Where is the .aia? I didn´t find it

I have updated the instructable by providing the .aia file in step 10 try it now!.

i guess the comments section doesn`t support any files but only images

i uploaded the file but something has went wrong,let me check!

nogueira (author)2017-11-07

Sorry, I meant "share"

About This Instructable

3,676views

72favorites

License:

Bio: I like to do robotics and automation projects.* denke anders!(think different)
More by einzigartig arun:Learn SERVO Control (at a Glance)Learn ARDUINO(in 20 Mins)HDPE Bottle Recycle(using Pressure Cooker)
Add instructable to: