Final Mini Project Doc.docx

  • Uploaded by: Srivathsav Reddy
  • 0
  • 0
  • July 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Final Mini Project Doc.docx as PDF for free.

More details

  • Words: 8,254
  • Pages: 47
CHAPTER-1 INTRODUCTION

Introduction to project: We live in an exciting time where more and more everyday things are becoming smart. Appliances have sensors and can communicate to other things and can provide control to more things. People have such hectic schedules that they just don’t have the time to worry about small things hence these were the IOT system comes in greater convenience, comfort time management and overall a better standard of living. The process of controlling or operating various equipment, machinery, industrial processes, and other applications using various control systems and also with less or no human intervention is termed as automation. There are various types of automation based on the application they can be categorized as home automation, industrial automation, autonomous automation, building automation, etc., In this project, let us discuss about wireless home automation using IOT (Internet of Things).

1.1Enabling Technologies for IOT: Internet of things (IOT) is a global infrastructure for the information society, enabling advanced services by interconnecting (physical and virtual) things based on existing and evolving interoperable information and communication technologies. With the Internet of Things the communication is extended via Internet to all the things that surround us. The Internet of Things is much more than machine to machine communication, wireless sensor networks, sensor networks , 2G/3G/4G,GSM,GPRS,RFID, WI-FI, GPS, microcontroller, microprocessor etc. These are considered as being the enabling technologies that make “Internet of Things” applications possible. Enabling technologies for the Internet of Things are considered and can be grouped into three categories: technologies that enable “things” to acquire contextual information, technologies that enable “things” to process contextual information, and technologies to improve security and privacy. The first two categories can be jointly understood as functional building blocks required building “intelligence” into “things”, which are indeed the features that differentiate the IOT from the usual Internet. The third category is not a functional but

1

rather a de facto requirement, without which the penetration of the IOT would be severely reduced. The Internet of Things is not a single technology, but it is a mixture of different hardware & software technology. The Internet of Things provides solutions based on the integration of information technology, which refers to hardware and software used to store, retrieve, and process data and communications technology which includes electronic systems used for communication between individuals or groups. There is a heterogeneous mix of communication technologies, which need to be adapted in order to address the needs of IOT applications such as energy efficiency, speed, security, and reliability. In this context, it is possible that the level of diversity will be scaled to a number a manageable connectivity technologies that address the needs of the IOT applications, are adopted by the market, they have already proved to be serviceable, supported by a strong technology alliance. Examples of standards in these categories include wired and wireless technologies like Ethernet, WI-FI, Bluetooth, ZIGBEE, GSM, and GPRS.

1.2 CHARACTERISTICS The fundamental characteristics of the IOT are as follows: 1.2.1 Connectivity: This doesn’t need much further explanation. Devices, sensors, they need to be connected: to an item, to each other, actuator, and a process and to ‘the Internet’ or another network. 1.2.2 Things: Anything that can be tagged or connected as such as it’s designed to be connected From sensors and household appliances to tagged livestock. Devices can contain sensors or sensing materials can be attached to devices and items. 1.2.3 Data: Data is the glue of the Internet of Things, the first step towards action and intelligence. 1.2.4 Communication: Devices get connected so they can communicate data and this data can be analyzed. 1.2.5 Intelligence: The aspect of intelligence as in the sensing capabilities in IOT devices and the intelligence gathered from data analytics (also artificial intelligence). 1.2.6 Action: The consequence of intelligence. This can be manual action, action based upon debates regarding phenomena (for instance in climate change decisions) and automation, often the most important piece.

2

1.2.7 Ecosystem: The place of the Internet of Things from a perspective of other technologies, communities, goals and the picture in which the Internet of Things fits. The Internet of Everything dimensions the platform dimension and the need for solid partnerships.

Fig 1.2 Characteristics of IOT

1.3 APPLICATION AREAS Potential applications of the IOT are numerous and diverse, permeating into practically all areas of every-day life of individuals, enterprises, and society as a whole. The IOT application covers “smart” environments/spaces in domains such as: Transportation, Building, City, Lifestyle, Retail, Agriculture, Factory, Supply chain, Emergency, Healthcare, User interaction, Culture and tourism, Environment and Energy. Below are some of the IOT applications.

3

1.3.1 IOSL (Internet of smart living): Remote Control Appliances: Switching on and off remotely appliances to avoid accidents and save energy, Weather: Displays outdoor weather conditions such as humidity, temperature, pressure, wind speed and rain levels with ability to transmit data over long distances, Smart Home Appliances: Refrigerators with LCD screen telling what’s inside, food that’s about to expire, ingredients you need to buy and with all the information available on a Smartphone app. Washing machines allowing you to monitor the laundry remotely, and. Kitchen ranges with interface to a Smartphone app allowing remotely adjustable temperature control and monitoring the oven’s self-cleaning feature, Safety Monitoring: cameras, and home alarm systems making people feel safe in their daily life at home, Intrusion Detection Systems: Detection of window and door openings and violations to prevent intruders, Energy and Water Use: Energy and water supply consumption monitoring to obtain advice on how to save cost and resources, & many more…

1.3.2 IOSC (Internet of smart cities): Structural Health: Monitoring of vibrations and material conditions in buildings, bridges and historical monuments, Lightning: intelligent and weather adaptive lighting in street lights, Safety: Digital video monitoring, fire control management, public announcement systems, Transportation: Smart Roads and Intelligent High-ways with warning messages and diversions according to climate conditions and unexpected events like accidents or traffic jams, Smart Parking: Real-time monitoring of parking spaces availability in the city making residents able to identify and reserve the closest available spaces, Waste Management: Detection of rubbish levels in containers to optimize the trash collection routes. Garbage cans and recycle bins with RFID tags allow the sanitation staff to see when garbage has been put out.

1.3.3 IOSE (Internet of smart environment): Air Pollution monitoring: Control of CO2 emissions of factories, pollution emitted by cars and toxic gases generated in farms, Forest Fire Detection: Monitoring of combustion gases and primitive fire conditions to define alert zones, Weather monitoring: weather conditions monitoring such as humidity, temperature, pressure, wind speed and rain, Earthquake Early Detection, Water Quality: Study of water suitability in rivers and the sea for eligibility in drinkable use, River Floods: Monitoring of water level variations in rivers, dams and reservoirs during rainy days, protecting wildlife: Tracking collars utilizing

4

GPS/GSM modules to locate and track wild animals and communicate their coordinates via SMS.

1.3.4 IOSI (Internet of smart industry): Explosive and Hazardous Gases: Detection of gas levels and leakages in industrial environments, surroundings of chemical factories and inside mines, Monitoring of toxic gas and oxygen levels inside chemical plants to ensure workers and goods safety, Monitoring of water, oil and gas levels in storage tanks and Cisterns, Maintenance and repair: Early predictions on equipment malfunctions and service maintenance can be automatically scheduled ahead of an actual part failure by installing sensors inside equipment to monitor and send reports.

1.3.5 IOSH (Internet of smart health): Patients Surveillance: Monitoring of conditions of patients inside hospitals and in old people’s home, Medical Fridges: Control of conditions inside freezers storing vaccines, medicines and organic elements, Fall Detection: Assistance for elderly or disabled people living independent, Dental: Bluetooth connected toothbrush with Smartphone app analyzes the brushing uses and gives information on the brushing habits on the Smartphone for private information or for showing statistics to the dentist, Physical Activity Monitoring: Wireless sensors placed across the mattress sensing small motions, like breathing and heart rate and large motions caused by tossing and turning during sleep, providing data available through an app on the Smartphone.

1.3.6 IOSE (internet of smart energy): Smart Grid: Energy consumption monitoring and management, Wind Turbines/ Power house: Monitoring and analyzing the flow of energy from wind turbines & power house, and two-way communication with consumers’ smart meters to analyze consumption patterns, Power Supply Controllers: Controller for AC-DC power supplies that determines required energy, and improve energy efficiency with less energy waste for power supplies related to computers, telecommunications, and consumer electronics applications, Photovoltaic Installations: Monitoring and optimization of performance in solar energy plants.

1.3.7 IOSA (internet of smart agriculture): Green Houses: Control micro-climate conditions to maximize the production of fruits and vegetables and its quality, Compost: Control of humidity and temperature levels in alfalfa, hay, straw, etc. to prevent fungus and other microbial contaminants, Animal 5

Farming/Tracking: Location and identification of animals grazing in open pastures or location in big stables, Study of ventilation and air quality in farms and detection of harmful gases from excrements, Offspring Care: Control of growing conditions of the offspring in animal farms to ensure its survival and health, field Monitoring: Reducing spoilage and crop waste with better monitoring, accurate ongoing data obtaining, and management of the agriculture fields, including better control of fertilizing, electricity and watering.

6

CHAPTER-2 WORKING CONDITION AND PRINCIPLE The designing methodology of the system has two major portions: software design and hardware design. The hardware is designed by arranging microcontroller to lights and fan, where as software design includes programming that is written and uploaded in the microcontroller. The designed system shows microcontroller connected to power supply and Relay for monitoring and controlling household devices. This design section shows how different hardware components are set up. The specifications and information regarding various components are described below. 1. Node MCU (Node Microcontroller Unit) -It is the central co-coordinator of the sensors and the actuators. This micro controller has built-in support for Wi-Fi connectivity which allows it to send and receive data from mobile application via internet server. It reads sensor data and sends them to mobile application and receives commands from mobile application to control home appliances. It then drives the relay-module to control the appliances. 2. Mobile application- Blynk, a platform with IOS and android apps, provides widgets to display data received from node MCU and control output signals(to control loads) from node MCU to the actuator circuits. 3. Internet server-Blynk mobile application in smart phone and node MCU communicate by using Blynk server. Bidirectional transfer of data between node MCU and mobile app occurs through this server. 4. Switching modules-One such module is used for turning light on/off and the other one is used for turning fan on/off. The output signal from node MCU activates and deactivates the relay to perform switching operation. 5. Interfacing module-Besides having relay, this circuit consists of a diac, a triac, a capacitor and two resistances with different values for obtaining high and low speeds by altering firing angle of a triac. The circuit works on AC phase chopping principle to control fan speed. To reduce RF interference a choke coil can be added to the circuit.

2.1 INSTALLATION OF LIBRARIES IN ARDUINO SOFTWARE: 2.1.1 ESP8266 LIBRARY : Firstly open Arduino IDE software. Go to files and click on the preference in the Arduino IDE. 7

Fig: 2.1.1

Copy the below code in the Additional boards Manager. Http://arduino.esp8266.com/stable/package_esp8266com_index.json click OK to close the preference Tab.

8

Fig: 2.1.2

After completing the above steps, go to Tools and board, and then select board Manager.

9

Fig: 2.1.3

Navigate to esp8266 by esp8266 community and install the software for Arduino. Once all the above process has been completed we are ready to program our esp8266 with Arduino IDE.

10

2.1.2 BLYNK LIBRARY: First open the Arduino IDE

Fig: 2.1.4 Install latest version of Blynk library.

Fig: 2.1.5 Once all the above process has been completed we are ready to program our Blynk with Arduino IDE.

11

2.2 SOURCE CODE: /************************************************************** * Blynk is a platform with iOS and Android apps to control * Arduino, Raspberry Pi and the likes over the Internet. * You can easily build graphic interfaces for all your * Projects by simply dragging and dropping widgets. * Downloads, docs, tutorials: http://www.blynk.cc * Blynk community: * Social networks: *

http://community.blynk.cc http://www.fb.com/blynkapp

http://twitter.com/blynk_app

* Blynk library is licensed under MIT license * This example code is in public domain. ************************************************************** * This example runs directly on ESP8266 chip. * * You need to install this for ESP8266 development: * https://github.com/esp8266/Arduino * * Please be sure to select the right ESP8266 module * in the Tools -> Board menu! * * Change Wi-Fi ssid, pass, and Blynk auth token to run :) * **************************************************************/

#define BLYNK_PRINT Serial

// Comment this out to disable prints and save space

#include <ESP8266WiFi.h> #include

// You should get Auth Token in the Blynk App. // Go to the Project Settings (nut icon). char auth[] = "auth token";

12

// Your Wi-Fi credentials. // Set password to "" for open networks. char ssid[] = "ssid"; char pass[] = "pwd";

void setup() { Serial.begin(9600); Blynk.begin(auth, ssid, pass); }

void loop() { Blynk.run(); }

2.2.1 AUTH TOKEN: In order to connect Blynk App and your hardware, you need an Auth Token. Create a new account in Blynk App. Create a New Project. Then choose the board and connection you will use. After the project was created, we will send you Auth Token over email. Check your email inbox and find the Auth Token. 2.2.2 SSID and PASSWORD: The Wi-Fi Manager is a great library does add to your ESP8266 projects, because using this library you no longer has to hard-core your network credentials (SSID and PASSWORD). Once a new SSID and Password is set, the ESP reboots and tries to connect; if it establishes a connection, the process is completed successfully. You need to step up a Hotspot (or) Wi-Fi whose SSID and Password are to be written in the source code.

13

2.3 WORKING: 

After setting Auth Token, SSID and Password compile the program.



If compiling is done then upload the program to the node MCU which is connected to the pc by a USB type B cable.



Now as you upload the source code into the Node MCU it will be connected to the Wi-Fi you provided in the source code and will create an interface between the Blynk App and Node MCU.



As you open the Blynk app, you can see that you are online and thus you can control the devices in Blynk app using an internet connection anywhere around the world.

2.4 BLYNK APP: Step1: For new users Sign Up and old users just Log in. Step2: Create a New Project and Choose Node MCU board in the Choose device drop-down and then click create.

14

Fig: 2.4.1

15

Fig: 2.4.2 Step3: Now you will receive an email with the Authentication Token. You need to place it in the ARDUINO Code. Before that, we will finish the App Creation. Step4: Click on the ‘+’ Icon on the top right corner. Now Widget box will open, We need 4 buttons to control the relay. So add 4 buttons by choosing it here.

16

Fig: 2.4.3 Step5: Now tap on the button from the Homepage to configure it. Choose the Output Pin D0 and Select the Mode as Switch. Then go back. Configure the remaining buttons in the same way.

17

Fig: 2.4.4 Step6: Now we have the App ready.

18

Fig: 2.4.5 Step7: Now connect the Node MCU to the laptop and open ARDUINO IDE. Install the Blink library here if you are doing it for the first time. You need to download the zip file and place it in the Libraries Folder. In case, you are using ESP8266 or Node MCU for the first time you need to add Node MCU on board’s manager. Please refer the Official Tutorial here for this. Step 8: Copy the following code or Open File->Examples and navigate to BLYNK > Wi-Fi > Node MCU. You need to modify only three things in this code. 19

Paste the Authentication Token that you received in your email at ‘Your Auth Token’. Then add your SSID and Password in the code as ‘Your Network Name’ and ‘Your Password’. Step 9: Then there is a function called Blynk.Run (). This is the most important function as this function keeps on listening for data and command from the Blink server which in turn receives the command from the Blink app on your smart phone. Thus the devices can be controlled from anywhere around the world.

20

CHAPTER-3 DESCRIPTION OF BLOCK DIAGRAM AND HARDWARE COMPONENTS 3.1 BLOCK DIAGRAM: The block diagram of IOT based Home Automation system is shown in the below figure 3.1. The figure below consists of the following sections: 

Power supply



Node MCU



Relay



Fan



Led’s



Wi-Fi/Hotspot



Blink App

LED 1

POWER SUPPLY

NODE MCU

WIFI / HOTSPOT

LED 2

RELAY

FAN

INTERNET

BLYNK APP

Fig3.1: Block diagram

21

3.2NodeMCU: Node MCU was created shortly after the ESP8266 came out. On December 30, 2013, Es-press-if Systems began production of the ESP8266. The ESP8266 is a Wi-Fi SOC integrated with a Ten silica Tense LX106 core, widely used in IOT applications (see related projects). Node MCU started on 13 Oct 2014, when Hong committed the first file of Node MCU-firmware to gather. Two months later, the project expanded to include an openhardware platform when developer Huang R committed the gerber file of an ESP8266 board, named davit v0.9. Later that month, Tuan PM ported MQTT client library from Contiki to the ESP8266 Sock platform, and committed to Node MCU project, then Node MCU was able to support the MQTT Iota protocol, using Lau to access the MQTT broker. Another important update was made on 30 Jan 2015, when Devsaurus ported the u8glib to Node MCU project, enabling Node MCU to easily drive LCD, Screen, OLED, even VGA displays. Due to resource constraints users need to select the modules relevant for their project and build a firmware tailored to their needs. 3.2.1 ESP8266 ARDUINO CORE: As Arduino.cc began developing new MCU boards based on non-AVR processors like the ARM/SAM MCU and used in the ARDUINO Due, they needed to modify the ARDUINO IDE so that it would be relatively easy to change the IDE to support alternate tool chains to allow ARDUINO C/C++ to be compiled down to these new processors. They did this with the introduction of the Board Manager and the SAM Core. A "core" is the collection of software components required by the Board Manager and the Arduino IDE to compile an Arduino C/C++ source file down to the target MCU's machine language. Some creative ESP8266 enthusiasts have developed an Arduino core for the ESP8266 Wi-Fi SOC that is available at the Gather ESP8266 Core webpage. This is what is popularly called the "ESP8266 Core for the Arduino IDE" and it has become one of the leading software development platforms for the various ESP8266 based modules and development boards, including Node MCU. Development boards, such as Arduino and Raspberry Pi, are common choices when prototyping new IOT devices. Those development boards are essentially mini-computers that can connect to and be programmed by a standard PC or Mac. After it has been programmed, the development boards can then connect to and control sensors in the field. (You can read more about IOT development hardware in this developer Works article.)

22

Because the "I" in IOT stands for internet, the development boards need a way to connect to the internet. In the field, the best way to connect to the internet is by using wireless networks. However, Arduino and Raspberry Pi do not have built-in support for wireless networks. Developers will have to add a Wi-Fi or cellular module to the board and write code to access the wireless module. NodeMCU most unique features are that it has built-in support for waif connectivity, and hence makes IOT application development much easier. The NodeMCU (Node Microcontroller Unit) is open source software and hardware development environment that is built around a very inexpensive System-on-a-Chip (SOC) called the ESP8266. The ESP8266, designed and manufactured by Es-press-if Systems, contains all crucial elements of the modern computer: CPU, RAM, networking (Wi-Fi), and even a modern operating system and SDK. When purchased at bulk, the ESP8266 chip costs only $2 USD a piece. That makes it an excellent choice for IOT projects of all kinds. However, as a chip, the ESP8266 is also hard to access and use. You have to solder wires, with the appropriate Analog voltage, to its PINs for the simplest tasks such as powering it on or sending a keystroke to the "computer" on the chip. And, you have to program it in low-level machine instructions that can be interpreted by the chip hardware. While this level of integration is not a problem when the ESP8266 is used as an embedded controller chip in mass-produced electronics, it is a huge burden for hobbyists, hackers, or students who want to experiment with it in their own IOT projects. Borrowing a page from the successful playbooks of Arduino or a Raspberry Pi, the Node MCU project aims to simplify ESP8266 development. It has two key components. An open source ESP8266 firmware that is built on top of the chip manufacturer's proprietary SDK. The firmware provides a simple programming environment based on eLua (embedded Lua), which is a very simple and fast scripting language with an established developer community. For new comers, the Lua scripting language is easy to learn. A DEVKIT board that incorporates the ESP8266 chip on a standard circuit board. The board has a built-in USB port that is already wired up with the chip, a hardware reset button, Wi-Fi antenna, LED lights, and standard-sized GPIO (General Purpose Input Output) pins that can plug into a bread board. Figure 1 shows the DEVKIT board, and Figure 2 shows the schema of its pins.

23

Fig3.2: Pin diagram of Node MCU Features 

32-bit RISC CPU: Tensilica Xtensa LX106 running at 80 MHz*



64 KB of instruction RAM, 96 KB of data RAM (80x Arduino UNO!)



512 KB of EEPROM (512x Arduino UNO!)



External QSPI flash – 512 KB to 4 MB* (up to 16 MB is supported)



IEEE 802.11 b/g/n Wi-Fi



Integrated TR switch, balun, LNA, power amplifier and matching network



WEP or WPA/WPA2 authentication, or open networks



16 GPIO pins



SPI, I²C,



I²S interfaces with DMA (sharing pins with GPIO)



UART on dedicated pins, plus a transmit-only UART can be enabled on GPIO2



1 10-bit ADC



USB micro connection



80 MHz clock (5x Arduino UNO or mega!)



Both the CPU and flash clock speeds can be doubled by over clocking on some devices. CPU can be run at 160 MHz and flash can be sped up from 40 MHz to 80 MHz Success varies chip to chip.

24

Note: The NodeMCU operates safely at 3.3v and does not have a 5v out pin. To use 5v devices like servos you’ll need an extra circuit. There are some ways the NodeMCU will safely work with 5v, but we do not recommend it. WHY NODEMCU? 

NodeMCU is open source IOT platform.



Low cost.



Integrated support for the WI-FI network.



Reduced size of the board.



Low energy consumption.

3.3 RELAY: 3.3.1 INTRODUCTION: A relay is an electromechanical switch, which perform ON and OFF operations without any human interaction. General representation of double contact relay is shown in fig. Relays are used where it is necessary to control a circuit by a low-power signal (with complete electrical isolation between control and controlled circuits), or where several circuits must be controlled by one signal.

Fig 3.3.1 Relay 3.3.2 History: The first relay was invented by Joseph Henry in 1835. The name relay derives from the French noun relays’ that indicates the horse exchange place of the postman. Generally a relay is an electrical hardware device having an input and output gate. The output gate consists in one or more electrical contacts that switch when the input gate is electrically excited. It can implement a decoupled, a router or breaker for the electrical power, a negation, and, on the base of the wiring, complicated logical functions containing and, or, and flip-flop. In the past relays had a wide use, for instance the telephone switching or the railway routing and crossing systems. In spite of electronic progresses (as programmable devices), relays are 25

still used in applications where ruggedness, simplicity, long life and high reliability are important factors (for instance in safety applications) 3.3.3 Working: Generally, the relay consists a inductor coil, a spring (not shown in the figure), Swing terminal, and two high power contacts named as normally closed (NC) and normally opened (NO). Relay uses an Electromagnet to move swing terminal between two contacts (NO and NC). When there is no power applied to the inductor coil (Relay is OFF), the spring holds the swing terminal is attached to NC contact.

Fig 3.3.2 Representation of Relay Whenever required power is applied to the inductor coil, the current flowing through the coil generates a magnetic field which is helpful to move the swing terminal and attached it to the normally open (NO) contact. Again when power is OFF, the spring restores the swing terminal position to NC. 3.3.4 Advantage of relay: A relay takes small power to turn ON, but it can control high power devices to switch ON and OFF. Consider an example; a relay is used to control the ceiling FAN at our home. The ceiling FAN may runs at 230V AC and draws a current maximum of 4A. Therefore the power required is 4X230 = 920 watts. Off course we can control AC, lights, etc., depend up on the relay ratings. Relays can be used to control DC motors in ROBOTICs. 3.3.5 Relay Driver Circuit: The ULN2003 is a monolithic IC consists of seven NPN Darlington transistor pairs with high voltage and current capability. It is commonly used for applications such as relay drivers, motor, display drivers, led lamp drivers, logic buffers, line drivers, hammer drivers 26

and other high voltage current applications. It consists of common cathode clamp diodes for each NPN Darlington pair which makes this driver IC useful for switching inductive loads.

Fig 3.3.3 Relay Driver Circuit The output of the driver is open collector and the collector current rating of each Darlington pair is 500mA. Darlington pairs may be paralleled if higher current is required. The driver IC also consists of a 2.7KΩ base resistor for each Darlington pair. Thus each Darlington pair can be operated directly with TTL or 5V CMOS devices. This driver IC can be used for high voltage applications up to 50V.

27

Fig 3.3.4 Logic Diagram of ULN2003 Note that the driver provides open collector output, so it can only sink current, cannot source. Thus when a 5V is given to 1B terminal, 1C terminal will be connected to ground via Darlington pair and the maximum current that it can handle is 500A. From the above logic diagram we can see that cathode of protection diodes are shorted to 9th pin called COM. So for driving inductive loads, it must connect to the supply voltage. ULN2003 is widely used in relay driving and stepper motor driving applications. Features: 

500mA rated collector current (Single output)



High-voltage outputs: 50V



Inputs compatible with various types of logic.



Relay driver application

3.4 POWER SUPPLY CIRCUIT: As in below figure this circuit is an approach to obtain both 12V and 5V DC power supply. The circuit uses two ICs 7812(IC1) and 7805 (IC2) for obtaining the required

28

voltages. The AC mains voltage will be stepped down by the transformer T1, rectified by filtered by capacitor C1 to obtain a steady DC level .The IC1 regulates this voltage to bridge B1 and obtain a steady 12V DC. The output of the IC1 will be regulated by the IC2 to obtain a steady 5V DC at its output. In this way both 12V and 5V DC are obtained. Such a circuit is very useful in cases when we need two DC voltages for the operation of a circuit. The LM78XX series of three terminal positive regulators are available in the TO-220 package and with several fixed output voltages, making them useful in a wide range of applications. Each type employs internal current limiting, thermal shut down and safe operating area protection, making it essentially indestructible. If adequate heat sinking is provided, they can deliver over 1A output current. Although designed primarily as fixed voltage regulators, these devices can be used with external components to obtain adjustable voltages and currents. The power supply section is the section which provide +5V for the components to work. IC LM7805 is used for providing a constant power of +5V. The ac voltage, typically 220V, is connected to a transformer, which steps down that ac voltage down to the level of the desired dc output. A diode rectifier then provides a full-wave rectified voltage that is initially filtered by a simple capacitor filter to produce a dc voltage. This resulting dc voltage usually has some ripple or ac voltage variation. A regulator circuit removes the ripples and also retains the same dc value even if the input dc voltage varies, or the load connected to the output dc voltage changes. This voltage regulation is usually obtained using one of the popular voltage regulator IC units.

Fig 3.4.1 Block Diagram Of Power Supply 3.4.1 Transformer: Transformers convert AC electricity from one voltage to another with little loss of power. Transformers work only with AC and this is one of the reasons why mains electricity is AC. Step-up transformers increase voltage, step-down transformers reduce voltage. Most power supplies use a step-down transformer to reduce the dangerously high mains voltage (230V in India) to a safer low voltage. 29

The input coil is called the primary and the output coil is called the secondary. There is no electrical connection between the two coils; instead they are linked by an alternating magnetic field created in the soft-iron core of the transformer. Transformers waste very little power so the power out is (almost) equal to the power in. Note that as voltage is stepped down current is stepped up. The transformer will step down the power supply voltage (0-230V) to (0- 6V) level. Then the secondary of the potential transformer will be connected to the bridge rectifier, which is constructed with the help of PN junction diodes. The advantages of using bridge rectifier are it will give peak voltage output as DC. Rectifier There are several ways of connecting diodes to make a rectifier to convert AC to DC. The bridge rectifier is the most important and it produces full-wave varying DC. A full-wave rectifier can also be made from just two diodes if a centre-tap transformer is used, but this method is rarely used now that diodes are cheaper. A single diode can be used as a rectifier but it only uses the positive (+) parts of the AC wave to produce half-wave varying DC Bridge Rectifier When four diodes are connected as shown in figure, the circuit is called as bridge rectifier. The input to the circuit is applied to the diagonally opposite corners of the network, and the output is taken from the remaining two corners. Let us assume that the transformer is working properly and there is a positive potential, at point A and a negative potential at point B the positive potential at point A will forward bias D3 and reverse bias D4.

Fig3.4.2 Bridge Rectifier

The negative potential at point B will forward bias D1 and reverse D2. At this time D3 and D1 are forward biased and will allow current flow to pass through them; D4 and D2 are reverse biased and will block current flow. 30

One advantage of a bridge rectifier over a conventional full-wave rectifier is that with a given transformer the bridge rectifier produces a voltage output that is nearly twice that of the conventional full-wave circuit. i. The main advantage of this bridge circuit is that it does not require a special centre tapped transformer, thereby reducing its size and cost. ii. The single secondary winding is connected to one side of the diode bridge network and the load to the other side as shown below. iii. The result is still a pulsating direct current but with double the frequency.

Fig 3.4.3 Output Waveform of DC

3.4.2 Smoothing: Smoothing is performed by a large value electrolytic capacitor connected across the DC supply to act as a reservoir, supplying current to the output when the varying DC voltage from the rectifier is falling. The capacitor charges quickly near the peak of the varying DC, and then discharges as it supplies current to the output. 3.4.3 Voltage Regulators: Voltage regulators comprise a class of widely used ICs. Regulator IC units contain the circuitry for reference source, comparator amplifier, control device, and overload protection all in a single IC. IC units provide regulation of either a fixed positive voltage, a fixed negative voltage, or an adjustably set voltage. The regulators can be selected for operation with load currents from hundreds of milli amperes to tens of amperes, corresponding to power ratings from milli watts to tens of watts. A fixed three-terminal voltage regulator has an unregulated dc input voltage, Vi, applied to one input terminal, a regulated dc output voltage, Vo, from a second terminal, with the third terminal connected to ground. 31

The series 78 regulators provide fixed positive regulated voltages from 5 to 24 volts. Similarly, the series 79 regulators provide fixed negative regulated voltages from 5 to 24 volts. Voltage regulator ICs are available with fixed (typically 5, 12 and 15V) or variable output voltages. They are also rated by the maximum current they can pass. Negative voltage regulators are available, mainly for use in dual supplies. Most regulators include some automatic protection from excessive current ('overload protection') and overheating ('thermal protection'). Many of the fixed voltage regulator ICs has 3 leads and look like power transistors, such as the 7805 +5V 1Amp regulator. They include a hole for attaching a heat sink if necessary.

Fig 3.4.4 Regulator

Fig 3.4.5 Circuit Diagram of Power Supply 3.5 FAN (DC 12V): Features 

Voltage: 12V DC



Size (W x H x D): 50 x 50 x 15mm



Airflow: 17 CFM



Power: 1.1W

Advantages: i. Minimal electromagnetic interference: Because the electromagnetic interference of DC fans is minimal, sensitive electronic devices often use DC fans to prevent electromagnetic interference. For example, computer 32

applications and equipment rely on DC fans, as they prevent overheating while still minimizing electromagnetic interference that could negatively affect sensitive applications. ii. Consumes less power: DC fans are widely regarded as the most efficient type of fan. They consume significantly less power than AC fans. In fact, DC fans consume up to 70 percent less energy to produce the same output as other fan types. For example, that means that a 25-watt DCdriven fan uses the same power as a 100-watt AC-driven fan. This is ideal for commercial settings, like restaurants, allowing you to keep fans running all day without incurring astronomical electric bills. iii. Quieter: DC fans make use of a new type of electrically commutated motor (ECM). Not only are these motors ultra-efficient, they are also incredibly quiet. Because they are so quiet, DC fans are an excellent option for applications such as medical instruments, telecom switches, or car entertainment systems, where noise could be a nuisance. iv. Lower voltage: DC fans generally use less voltage than AC fans. The majority of DC fans are lowvoltage fans. For example, you can typically find 5V, 12V, and 24V versions of DC fans. Larger models of DC fans, such as 119mm to 172mm fan models, are typically available in 48V. In comparison, most AC cooling fan models are available in 115V, a much higher voltage. Lower voltage also makes DC fans potentially less dangerous.

Fig 3.5 DC Fan

33

3.6 Light Emitting Diode (LED): A light-emitting diode (LED) is a semiconductor device that emits visible light when an electric current passes through it. The light is not particularly bright, but in most LEDs it is monochromatic, occurring at a single wavelength. The output from an LED can range from red (at a wavelength of approximately 700 nanometres) to blue-violet (about 400 nanometres). An LED consists of two elements of processed material called P-type semiconductors and Ntype semiconductors. These two elements are placed in direct contact, forming a region called the P-N junction. In this respect, the LED resembles most other diode types, but there are important differences. The LED has a transparent package, allowing visible energy to pass through. Also, the LED has a large PN-junction area whose shape is tailored to the application. Benefits of LED’S: 

Low power requirement



High efficiency



Long life



Indicator lights



LCD panel backlighting



Remote control

Fig 3.6 LED

3.7 Jumper Wires: A jump wire (also known as jumper, jumper wire, jumper cable, DuPont wire, or DuPont cable – named for one manufacturer of them) is an electrical wire, or group of them in a cable, with a connector or pin at each end (or sometimes without them – simply "tinned"), which is normally used to interconnect the components of a breadboard or other prototype or test circuit, internally or with other equipment or components, without soldering. 34

Fig 3.7 Jumper wires

3.8 WI-FI: Wi-Fi or Wi-Fi (/ˈwaɪfaɪ/) is a technology for wireless local area networking with devices based on the IEEE 802.11 standards. Wi-Fi is a trademark of the Wi-Fi Alliance, which restricts

the

use

of

the

term Wi-Fi

Certified to

products

that

successfully

complete interoperability certification testing. Devices that can use Wi-Fi technology include personal computers, video-game consoles, phones and tablets, digital cameras, smart TVs, digital audio players and modern printers. Wi-Fi compatible devices can connect to the Internet via a WLAN and a wireless access point. Such an access point (or hotspot) has a range of about 20 meters (66 feet) indoors and a greater range outdoors. Hotspot coverage can be as small as a single room with walls that block radio waves, or as large as many square kilometres achieved by using multiple overlapping access points.

Fig 3.8 WI-FI Depiction of a device sending information wirelessly to another device, both connected to the local network, in order to print a document. 35

Wi-Fi most commonly uses the 2.4 gigahertz (12 cm) UHF and 5.8 gigahertz (5 cm) SHF ISM radio bands. Anyone within range with a wireless modem can attempt to access

the

network;

because

of

this,

Wi-Fi

is

more

vulnerable

to

attack

(called eavesdropping) than wired networks. Wi-Fi Protected Access is a family of technologies created to protect information moving across Wi-Fi networks and includes solutions for personal and enterprise networks. Security features of Wi-Fi Protected Access constantly evolve to include stronger protections and new security practices.

Software Introduction: 3.9 Arduino IDE Software: You can get different versions of Arduino IDE from the Download page on the Arduino Official website. You must select your software, which is compatible with your operating system (Windows, IOS, or Linux). After your file download is complete, unzip the file.

Fig 3.9.1 Launch Arduino IDE. After your Arduino IDE software is downloaded, you need to unzip the folder. Inside the folder, you can find the application icon with an infinity label (application.exe). Double-click the icon to start the IDE. 36

Fig 3.9.2 Open your first project. Once the software starts, you have two options:  Create a new project.  Open an existing project example.

37

To create a new project, select File --> New

Fig 3.9.3

Fig 3.9.4

38

Here, we are selecting just one of the examples with the name Blink. It turns the LED on and off with some time delay. You can select any other example from the list Select your serial port. Select the serial device of the Arduino board. Go to Tools -> Serial Port menu. This is likely to be COM3 or higher (COM1 and COM2 are usually reserved for hardware serial ports). To find out, you can disconnect your Arduino board and re-open the menu, the entry that disappears should be of the Arduino board. Reconnect the board and select that serial port.

Fig 3.9.5 Before explaining how we can upload our program to the board, we must demonstrate the function of each symbol appearing in the Arduino IDE toolbar. 

Used to check if there is any compilation error.



Used to upload a program to the Arduino board.



Shortcut used to create a new sketch.



Used to directly open one of the example sketch.



Used to save your sketch.

Serial monitor used to receive serial data from the board and send the serial data to the board. Now, simply click the "Upload" button in the environment. Wait a few seconds; you will see the RX and TX LEDs on the board, flashing. If the upload is successful, the message "Done uploading" will appear in the status bar.

39

Fig 3.9.6 In this chapter, we will study in depth, the Arduino program structure and we will learn more new terminologies used in the Arduino world. The Arduino software is opensource. The source code for the Java environment is released under the GPL and the C/C++ microcontroller libraries are under the LGPL. Sketch: The first new terminology is the Arduino program called “sketch”. Structure Arduino programs can be divided in three main parts: Structure, Values (variables and constants), and Functions. In this tutorial, we will learn about the Arduino software program, step by step, and how we can write the program without any syntax or compilation error. Let us start with the Structure. Software structure consists of two main functions: Setup ( ) function. Loop ( ) function.

40

Fig 3.9.7 A data type in C refers to an extensive system used for declaring variables or functions of different types. The type of a variable determines how much space it occupies in the storage and how the bit pattern stored is interpreted. The following table provides all the data types that you will use during Arduino programming.

3.10 Blynk app: Blynk is a Platform with iOS and Android apps to control Arduino, Raspberry Pi and the likes over the Internet. It's a digital dashboard where you can build a graphic interface for your project by simply dragging and dropping widgets. It’s really simple to set everything up and you'll start tinkering in less than 5 mins. Blynk is not tied to some specific board or shield. Instead, it's supporting hardware of your choice. Whether your Arduino or Raspberry Pi is linked to the Internet over Wi-Fi, Ethernet or this new ESP8266 chip, Blynk will get you online and ready for the Internet of Your Things.

41

Fig 3.10 Blynk app in ios and android.

42

CHAPTER-4 ADVANTAGES, APPLICATIONS AND RESULT ANALYSIS 4.1 ADVANTAGES: 4.1.1 Communication: IOT encourages the communication between devices, also famously known as Machine-to-Machine (M2M) communication. Because of this, the physical devices are able to stay connected and hence the total transparency is available with lesser inefficiencies and greater quality. 4.1.2 Automation and Control: Due to physical objects getting connected and controlled digitally and centrally with wireless infrastructure, there is a large amount of automation and control in the workings. Without human intervention, the machines are able to communicate with each other leading to faster and timely output. 4.1.3 Information: It is obvious that having more information helps making better decisions. Whether it is mundane decisions as needing to know what to buy at the grocery store or if your company has enough widgets and supplies, knowledge is power and more knowledge is better. 4.1.4 Monitor: The second most obvious advantage of IoT is monitoring. Knowing the exact quantity of supplies or the air quality in your home, can further provide more information that could not have previously been collected easily. For instance, knowing that you are low on milk or printer ink could save you another trip to the store in the near future. Furthermore, monitoring the expiration of products can and will improve safety. 4.1.5 Efficient and saves time: The machine-to-machine interaction provides better efficiency, hence; accurate results can be obtained fast. This results in saving valuable time. Instead of repeating the same tasks every day, it enables people to do other creative jobs. As hinted in the previous examples, the amount of time saved because of IOT could be quite large. And in today’s modern life, we all could use more time. 4.1.6 Saves Money: The biggest advantage of IOT is saving money. If the price of the tagging and monitoring equipment is less than the amount of money saved, then the Internet of Things will be very widely adopted. IOT fundamentally proves to be very helpful to people in their 43

daily routines by making the appliances communicate to each other in an effective manner thereby saving and conserving energy and cost. Allowing the data to be communicated and shared between devices and then translating it into our required way, it makes our systems efficient. Optimum utilization of energy and resources can be achieved by adopting this technology and keeping the devices under surveillance. We can be alerted in case of possible bottlenecks, breakdowns, and damages to the system. Hence, we can save money by using this technology. 4.1.7 Automation of daily tasks leads to better monitoring of devices: The IOT allows you to automate and control the tasks that are done on a daily basis, avoiding human intervention. Machine-to-machine communication helps to maintain transparency in the processes. It also leads to uniformity in the tasks. It can also maintain the quality of service. We can also take necessary action in case of emergencies. 4.1.8 Better Quality of Life: All the applications of this technology culminate in increased comfort, convenience, and better management, thereby improving the quality of life.

4.2 APPLICATIONS: Heating, ventilation and air conditioning (HVAC): it is possible to have remote control of all home energy monitors over the internet incorporating a simple and friendly user interface. Lighting control system: a "smart" network that incorporates communication between various lighting system inputs and outputs, using one or more central computing devices. Occupancy-aware control system: it is possible to sense the occupancy of the home using smart meters and environmental sensors like CO2 sensors, which can be integrated into the building automation system to trigger automatic responses for energy efficiency and building comfort applications. Appliance control and integration with the smart grid and a smart meter, taking advantage, for instance, of high solar panel output in the middle of the day to run washing machines. Home robots and security: a household security system integrated with a home automation system can provide additional services such as remote surveillance of security cameras over the Internet, or central locking of all perimeter doors and windows. 

Leak detection, smoke and CO detectors.



Indoor positioning systems (IPS). 44



Home automation for the elderly and disabled.



Pet And Baby Care, for example tracking the pets and babies movements and controlling pet access rights.



Air quality control. For example Air Quality Egg is used by people at home to monitor the air quality and pollution level in the city and create a pollution map.

4.3 RESULT:

Fig 4.3 Picture showing the control of devices in Blynk app.

45

CHAPTER-5 CONCLUSION AND FUTURE SCOPE 5.1 CONCLUSION: The home automation using Internet of things is experimentally proven by connecting simple appliances to it and the appliances were successfully controlled remotely form any place using internet with low cost and low power consumption. Also the status of the appliances is displayed.

5.2 FUTURE SCOPE: As with any industry, as Automation for residences become common place, the market will eventually be crowded with several players, multiple product offerings and competitive pricing. The market for just Home automation is estimated to be 3.2$ Billion by 2020. If IoT were to become common place, then we’re looking at a multi-billion dollar opportunity in the Indian market. We foresee that all major players will have a presence leading to competition in prices and lower margins. The products themselves will reach a ‘plug and play’ type of usability, where users can simply purchase pieces from the store and use it themselves without any support from professionals. Many (most) houses will incorporate some aspect of Automation in the home, from Lighting, security or HVAC elements. Home Automation will be as commonplace as having a Fridge or Television in the house. 5.2.1 Home Automation Market: By application 

Lighting.



Safety and security.



HVAC (Heating, Ventilation, and Air-Conditioning).



Entertainment (Home audio and video).



Others (Robotics, heath care).

5.2.2 Home Automation Market: By networking technology 

Wired home automation systems.



Power-line home automation systems.



Computing network home automation systems.



Wireless home automation systems. 46

5.2.3 Home Automation Market: By type 

Luxury (custom) home automation systems.



Mainstream home automation systems.



DIY (Do It Yourself) home automation systems.



Managed home automation services.

47

Related Documents

Mini Project Final Doc.docx
December 2019 10
Mini Project
April 2020 15
Mini Project
June 2020 13
Tqm Mini Project
June 2020 10

More Documents from "Noni Minty Belantric"