1 Technology (B-TECH Hons) in Electrical and hereby

1 INTERNET OF THINGS (IOT) BASED ENERGY METER READING Session 2014-2018 Submitted By Muhammad Tahir: SU-14-01-076-050 Shuaib Muhammad: SU-14-01-076-025 Shahid khan: SU-14-01-076-024 Taimour Hassan Jan: SU-14-01-076-027 Supervised By Engr. Noman Muslim Lecturer, Department of Technology Sarhad University Of Information Technology & IT Peshawar DEPARTMENT OF TECHNOLOGY, SARHAD UNIVERSITY OF SCIENCE AND INFORMATION TECHNOLOGY (SUIT) PESHAWAR-PAKISTAN2 APPROVAL SHEET The undersigned, appointed by the Dean of Faculty of Engineering and Technology, have examined the thesis entitled, Internet Of Things (IOT) Based Energy Meter Reading Presented By, Muhammad Tahir: SU-14-01-076-050 Shuaib Muhammad: SU-14-01-076-025 Shahid khan: SU-14-01-076-024 Taimour Hassan Jan: SU-14-01-076-027 The candidates for the degree of Bachelor of Technology (B-TECH Hons) in Electrical and hereby certify that, in their opinion, it is worthy of acceptance. Internal Supervisor: External Examiner: Engr. Muhammad Faisal Dr. Wasal Engr. Noman Muslim Supervisor Coordinator, Department of Technology Director, Department of Technology3 INTERNET OF THINGS (IOT) BASED ENERGY METER READING By Muhammad Tahir: SU-14-01-076-050 Shuaib Muhammad: SU-14-01-076-025 Shahid khan: SU-14-01-076-024 Taimour Hassan Jan: SU-14-01-076-027 A thesis Presented to the Sarhad University of Science & IT, Peshawar in partial fulfillment for the degree requirement of Bachelor of Technology In Electrical 2014-2018 Peshawar, Khyber Pakhtunkhwa, Pakistan4 AUTHOR’S DECLARATION We hereby declare that we are the sole authors of this thesis.

This is a true copy of the thesis, including any required final revisions, as accepted by my examiners. It is further declared, that we have fulfilled all the requirements in line with the quality assurance guideline of the Higher Education Commission.5 Abstract This project is designed to measure energy consumption in the house and generate its bill automatically using telemetric communication. This can help in reducing energy consumption in house as the owner is continuously being notified about the number of units that are consumed. It’s objective is to generate bill automatically by checking the electricity unit’s consumption in a house and in a way to reduce the manual labor. The Calculation are performed automatically and the bill is updated on the internet by using a network of Internet Of Things (IOT). The bill amount can be checked by the owner anywhere globally at any time.

We Will Write a Custom Essay Specifically
For You For Only $13.90/page!


order now

6 Acknowledgements All praises and thanks to AL-Mighty ALLAH, the most merciful and most gracious, the source of knowledge and wisdom endowed to mankind, who conferred us with the power of mind and capacity to take this project to exiting ocean of knowledge. All respects are for our most beloved Holy Prophet MUHAMMAD (S.A.W.W), who forever a torch of guidance for humanity as whole. We are grateful to our parents who have been so understanding, caring and generous with their prayers, all throughout this very tough period and of course, all of our teachers who have been a great help and an enormous source of inspiration.

During the course of this project when we got stuck in awkward positions, where nothing seemed to make sense, our teachers led us through those immensely dark tunnels. Most of our respected teachers helped us when we need it most. This is not just concerning the project, it has been so over the last four years and we will be able to thank them enough. We would specially like to thank the following parsons for their king support and technical help as without it, we would never be able to complete this project. ? Engr.

Fayyaz ? Engr. Noman Muslim ? Engr. Zia Uddin7 Dedication Every challenging work needs self efforts as well as guidance of elders especially those who were very close to our hearts. Our humble efforts we dedicate this whole progress to Almighty ALLAH. After that our beloved father and mother, brother and sister and all teachers whose love, encouragement and prays of day and night made us able to build such a tremendous device.

8 Table of Contents AUTHOR’S DECLERATION 4 Abstract 5 Acknowledgements 6 Dedication (optional) 7 Table of Contents 8 Chapter 1 INTRODUCTION & GENERAL INFORMATION 1.1 Introduction & background Of Project 10 1.2 Problem Statement 10 1.3 Objectives 11 1.

4 Scope Of Work 11 1.5 Project Expectation 11 Chapter 2 Theory Related to Project 2.1 Introduction 12 2.2 Nod MCU 12 2.2.1 Features 12 2.3 Arduino 13 2.4 Current Transformer 14 2.

5 Voltage Sensor 14 2.5.1 Features 14 2.6 Transformer 15 2.7 LCD 1602 169 2.

7.1 Features 17 Chapter 3 Hardware Implementation 3.1 Introduction 18 3.2 Guideline Methodology 18 3.

3 Requirements of Project 18 3.4 Hardware Needed 18 3.4.1 Tools to complete the task 18 3.5 Hardware Building Procedure 19 3.5.1 LCD Interface 19 3.

5.2 Node MCU 19 3.5.3 Voltage Sensor 20 3.5.4 Full Circuit Diagram 21 Chapter 4 Software 4.1 Introduction 22 4.

2 Arduino IDE 22 4.3 NOD MCU 24 4.4 Arduino Coding 25 4.5 NOD MCU Coding 28 Chapter 5 5.1 Conclusion 32 5.2 References 3210 CHAPTER 1 INTRODUCTION & GENERAL INFORMATION 1.

1 Introduction & background This project is designed to measure energy consumption in the house and generate its bill automatically using telemetric communication. This can help in reducing energy consumption in house as the owner is continuously being notified about the number of units that are consumed. It’s objective is to generate bill automatically by checking the electricity unit’s consumption in a house and in a way to reduce the manual labor. The Calculation are performed automatically and the bill is updated on the internet by using a network of Internet Of Things (IOT). The bill amount can be checked by the owner anywhere globally at any time. The IOT allow object to be sensed and controlled remotely across existing network infrastructure, creating opportunities for more direct integration between the physical world and computer based systems, resulting in improved efficiency, accuracy and economics benefits. The increasing generation needs empowered gadgets by wireless technology in which IOT technology has grown from its beginning and now presently widely being used.

1.2 Problem Of Statement Now days Digital and Analog meters are present but the main problem is that we have to hire the meter Reader for reading. Another problem is that we can’t get the real time reading. If any problem arises in the meter we can easily detect through remote area. It makes our meter more secure.11 1.3 Objectives 1.

To generate bill automatically by checking the electricity unit’s consumption in a house/industry and in a way to reduce the manual labor. 2. The bill will update on the internet by using a network of IOT due to which the bill will be checked by the owner anywhere globally at any time. 3. If in case consume fails to pay the bill on time then electricity transmission can automatically be turned off. 1.4 Scope of Project The project mainly aims at providing overall infrastructure of the energy meter. The main improvement for the future is going to make energy meter readings, connection and disconnection and also the pre information providing to the users all is going to happen on WIFI internet.

The overall information will be providing to the energy meter i.e WAPDA, will be easy for them to handle the things. Also in future we can go with some standard apps or standard tools, which will make work easy for WAPDA people reading the meter readings faster than the faster method. And connect and disconnect of every meters on the payment and non-payment that will be fast as compared to the present method. 1.5 Project Expectation 1 Develop the IOT Based Energy Meter Reading.

2 Learn to develop the program. 3 Learn how to connect the wiring of the circuit.12 Chapter 2 Theory Related to Project 2.1 Introduction: In this chapter we will discuss about the hardware that are used in this project. ? Node MCU.

? Arduino Pro mini. ? Current Transformer. ? Voltage sensor. ? Transformer. ? LED 1602. 2.2 Node MCU: Node MCU is a firmware and development kit that help you in your IOT product.

2.2.1 Features: ? Open Source: The code is available for study and changing for new development. ? Programmable: You can create your own program. ? Low Cost: The device is available at low cost. ? Wi-Fi enabled: Wi-Fi option is available for connectivity to other. Example of Code: Print(wifi.

sta.getip()) –nil Wifi.setmode(wifi.STATION) Wifi.sta.

config(“SSID”, “password”) Print(wifi.sta.getip())13 2.3 Arduino Pro mini: Arduino is minicomputer which is open source software and hardware. It is design as a variety of controllers and microprocessor. It has 16 digitals pin and 6 analogue. The language is used for programing is C and C++.

14 2.4 Current Transformer: The type of transformer in which the current is measure alternating current. It is also known by instrument transformer along with voltage. The function of instrument transformer is to reduce the large-scale voltage to small once. 2.5 Voltage Sensor: A sensor which determine and monitor or measure the voltage is known as voltage sensor. The measurement is taken and convert into signal which will become easily readable.

This device is installed in special electronic devices for recording, but sometimes an observer will be present to manually read the sensor output. 2.5.1 Features of Voltage sensor: ? Detect overvoltage or under voltage from 4 mV to 300 V. ? Detect undercurrent, reverse current, or overcurrent in DC circuit using shunt. ? Detect three-phase AC current for under and/or overcurrent using current converter.

? Available in 7 supply voltage configurations.15 ? Single-function model with on-delay, OFF-delay, or startup lock setting ? Select either AC or DC voltage input. 2.6 Transformer: Transformer is defined from its name transform, means the transfer of energy between two circuits through electromagnetic induction.One coil is transformer produce magnetic field, which turn into electrometer force.16 2.7 LCD 1602: The LCD 1602 is type of LCD display, which is used to show numbers, characters and letters in mini display.

It is made up of dot matrix to two resolution 5×7 or 5×11.17 2.7.

1 Feature: ? Mode Display: Bulb, STN. ? Format: 16-character x 2 line. ? Viewing: 6 o’clock. ? Input: 4-bits or 8-bits ? Font: 5 x 8 Dots. ? Power Supply: Single Power Supply(5V+-10%).18 Chapter 3 Hardware Implementation 3.1 Introduction In this project I will show you how to easily connect with your own IOT Network by using NodeMCU. Importance of Arduino in this project.

Interference of other hardware in this project. 3.2 Guideline Methodology The start of the flow work is to understand the importance of IOT Network. There are some requirements to execute the task. To connect with the IOT network we have a need of a special Microcontroller “ESP8266”.

ESP8266 is known as system on Chip(SOC). ESP8266 is a WIFI based Chip. It has a ability to connect with internet. 3.1: Requirements of Project ? WIFI ? Internet 3.2: Hardware needed ? NodeMCU (ESP8266) ? Arduino ? Current Transformer ? Voltage Sensor ? 1602 LCD ? WIFI Router ? Broad Band Internet 3.2.2 Tools to complete the task: ? • Screwdriver ? • Soldering iron ? • Solder ? • Cutting tool (e.

g. wire cutter) ? • Glue19 3.3 Hardware building procedure 3.3.1 LCD Interference LCD has a parallel communication port. We have attached LCD with NodeMCU. But NodeMCU can’t accept Parallel LCD at the start.

For that purpose we use Arduino. Arduino has handle all the work that problem are arises in NodeMCU. Figure 3.

1 LCD Interference 3.3.2 NodeMCU:- NodeMCU has the ability to connect with internet.

First we will connect the NodeMCU with WIFI. Then we will connect with MQTT server. Through this process we will connect with IOT network. Figure 3.2 Interference NODEMCU with Arduino20 3.

3.3 Voltage Sensor:- Voltage sensor is not directly connect with 220 V. To measure the 220 V we will use Step down transformer to measure 220 v. Figure 3.3 Voltage Sensor21 3.4 Full circuit diagram CIRCUIT CONNECTION DIAGRAM BLOCK DIAGRAM22 Chapter 4 SOFTWARE 4.

1 Introduction The Arduino platform provides software to program the Arduino microcontroller. These instructions are written using the C++ programming language.The libraries provided by the Arduino IDE, simplify the creation of simple features such as reading or writing on a port, and it is also possible to import other libraries created by Arduino users for their projects, which helps the development of other users’ projects The microcontroller can run code developed using the Arduino IDE.

The serial interface between the micro controller and the Wi-Fi module is realized using software. This project is implemented using ARDUINO software . Arduino consists of both a physical programmable circuit board (microcontroller) and IDE (Integrated Development Environment) that runs on your computer, used to write and upload computer code to the microcontroller. 4.2 ARDUINO IDE The Arduino integrated development environment (IDE) is a cross-platform application (for Windows, macOS, Linux) that is written in the programming language Java. .

It includes a code editor with features such as text cutting and pasting, searching and replacing text, automatic indenting, brace matching, and syntax highlighting, and provides simple one-click mechanisms to compile and upload programs to an Arduino board. It also contains a message area, a text console, a toolbar with buttons for common functions . The source code for the IDE is released under the GNU General Public License. The Arduino IDE supports the languages C and C++ using special rules of code structuring. The Arduino IDE supplies a software library from the Wiring project, which provides many common input and output procedures. have added up to an incredible amount of accessible knowledge that can be of great help to novices and experts alike.23 Official Arduino IDE screenshot.

On the top-left corner, several tools are available to validate and upload the developed code to the Arduino board. On the top-right corner a button shows up the serial console for debugging purposes. In the middle the sketch code is presented, and the bottom presents a console to feedback about error messages and upload status.24 4.3 NODE MCU NodeMCU is an open source IoT platform. It includes firmware which runs on the ESP8266 WiFi. It is a Single-board microcontroller.

It has 128kBytes of memory The NodeMCU (Node Micro Controller Unit) is an 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 Espressif Systems, contains all crucial elements of the modern computer: CPU, RAM, networking (wifi). This module is one of the cheapest available wifi-modules in market. V3 or Version3 is the latest version of this module. Headers: 15-pin header with access to GPIOs, SPI, UART, ADC, and power pins.

Power: 5V via micro USB port25 4.4 Arduino Coding //#define CAYENNE_DEBUG #define CAYENNE_PRINT Serial #include // WiFi network info. char ssid = “Tahir”; char wifiPassword = “TeLeCoMs”; // Cayenne authentication info. This should be obtained from the Cayenne Dashboard. char username = “30ad0620-0d5f-11e8-8620-addae6ef14ff”; char password = “dbcf07d35ee4d4bae740a132e02e5de499357cb5”; char clientID = “5380aa40-25f0-11e8-b59c-db84183bf26b”; int currentPin = 0; //Assign CT input to pin 1 double kilos = 0; int peakPower = 0; int RMSCurrentiot; int RMSPoweriot; int kilosiot; int peakPoweriot; void setup() { Serial.begin(9600); Cayenne.begin(username, password, clientID, ssid, wifiPassword); } void loop() { Cayenne.loop(); int current = 0; int maxCurrent = 0; int minCurrent = 1000;26 for (int i=0 ; i= maxCurrent) maxCurrent = current; else if(current

x

Hi!
I'm Mary!

Would you like to get a custom essay? How about receiving a customized one?

Check it out