Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 6

Design of Internet Controlled Switch Box using IoT

Name : Tran Ngoc Khoa


ID: 20173986
I. INTRODUCTION
As a student, its always fun to control electric devices by using a phone or
computer when we turn on/off the lights from far away, similarly you can also
switch on / off Fans, coffee machine etc By using IOT
IoT (Internet of things) is a developing technique that is more useful to control or
monitor the appliances via internet. Existing appliances can be connected to WIFI
network and to internet with the help of ESP8266 microcontroller. A web sever
d^gc thgc hien boi ESP8266 co thl d^gc kit n6i bang phin mim tren dien thoai
android. Home appliances connected in smart switch, people can control
appliances anytime anywhere. This paper gives overview of Internet Controlled
Switch
II. HARDWARE

a. KIT Wi-Fi

ESP8266 NodeMCU is an open source platform based on ESP8266 which can


connect objects and let data transfer using the Wi-Fi protocol. In addition, by
providing some of the most important features of microcontrollers such as GPIO,
PWM, ADC, and etc, it can solve many of the project’s needs alone.

{GPIQ16H USER H WAKE |


[TOUT }
[ RESERVED }-

[RES€RVSD}-
FLASH

y..... JHGPIOIOI- { GPIQ2 H TXPI 1 - P W M


GPIQ9 |~

MOSI

HGPIQ12|- HMISO |

[GPI013]

GPIOl H TXPO |

Figure 1. Pin diagram of ESP8266 NodeMCU.


b. POWER SUPPLY MODULE & CIRCUIT

Power supply unit is the important area that determines the stability of system.
The availability of raw source is 220 V, the controller which is used in the system
was operates at 3.3V. The transformer steps downs the mains voltage to 12V /
200mA which is then rectified by the four 1N4007 diodes and filtered by the
470uF 330nF capacitor and finally goes to the L78L33 IC which steps down the
voltage to 3.3V / 100mA. The 100nF capacitor is used to filter the output of the IC.

Figure 2. Schematic of power supply module

c. MODULE RELAY
The WI-FI switch was operated at DC voltage and to interlink this switch AC
source by using relays. The relay circuit gets input from the controller (WI-FI
switch) and controls the switch to Turn On or OFF. The interconnection of WI-FI
switch and the relay connection was shown below.

Figure 3. Module relay


III. SOFTWARE

a. WI-FI MODULE PROGRAMMER

The Arduino IDE is used to embed the coding to the Arduino board. The same
software package is used to ESP8266 switch by installing the ESP nodeMCU
switch driver. The programming language, coding syntax used for arduino is too
used here. The programmer window is shown below.

♦include <ESP8266WiFi.h>
♦include <ESP8266WebServer.h>
ESP8266WebServer webServer(80}; char* ssid
= "loan Thang"; char* pass = "0912574232";
/ / =====Bi#n chua ma HTLM Vebsite==//
const char MainPage[] PROGMEM = R"== (
<!DOCTYPE html>
<html>
<head>
<title>HOME PAGE</titie> |
<meta charset="OTF-8">
</head>
<body>
<hl>ESP8266 Web Server</hl>
<div>Em Khoa Remote <bxpan
id=ntrangthaiDl"><pan></bx/div>
<div>
<button class=”bt_on"
onclick="getdata(T
onDl')">ON</button> <button
class="bt_off"
onclicfc="getdata('offDl')">OFF</b
utton>
</div>
Figure 4 Programmer Window

b. ESP8266 WEB SEVER

The web sever is created using Eclipse- Java developer coding for to control
the Internet controlled switch for ON and OFF command using pre-defined
syntax’s. The Snap Shot of the websever was given below.
© HOME PAGE X+

<- -> C O © Not secure | 192.168.1.9/offD1

ESP8266 Web Server


Em Khoa Remote
ON IPOFFI

Figure 5 Web Sever Window


IV. SIMULATION

a. WIRE CONNECTION
ESP8266 NodeMCU Relay Led
VU => <= VCC
G => <= GND
D4 => <= IN
COM => <= Hot wire
NO => <= Hot wire

3.3V DC j

Figure 6 ESP Switch connected with Relay


b. RESULT

The smart switch by using ESP8266 and relay to control led was successfully
developed.
Shown in this link ( video): (Ctrl+click to follow link)

https://drive.google.com/open?id=16ANOUxbboYuhGdEljcGmHHsqOydKBnFo

V. CONCLUSIONS
This paper deals with the proposed basic design of Internet controlled switch
box. This paper contribute to an easy design of IoT device.
By keeping this paper as a base one using ESP switches the smart-home has
been planned to do in a future. Each and Every rooms will become automated
Thank you for listening

You might also like